Skip to content

Commit 4518086

Browse files
committed
Getting rid of commented out code.
1 parent bd07b8a commit 4518086

1 file changed

Lines changed: 1 addition & 70 deletions

File tree

cpp/ql/lib/experimental/Quantum/OpenSSL/EVPCipherAlgorithmSource.qll

Lines changed: 1 addition & 70 deletions
Original file line numberDiff line numberDiff line change
@@ -80,74 +80,5 @@ class CipherKnownAlgorithmLiteralAlgorithmInstance extends Crypto::CipherAlgorit
8080

8181
override string getRawAlgorithmName() { result = this.(Literal).getValue().toString() }
8282

83-
override Crypto::TCipherType getCipherFamily() {
84-
literalToCipherFamilyType(this, result)
85-
}
83+
override Crypto::TCipherType getCipherFamily() { literalToCipherFamilyType(this, result) }
8684
}
87-
// override Crypto::TCipherType getCipherFamily() {
88-
// if this.cipherNameMappingKnown(_, super.getAlgorithmName())
89-
// then this.cipherNameMappingKnown(result, super.getAlgorithmName())
90-
// else result instanceof Crypto::OtherCipherType
91-
// }
92-
// bindingset[name]
93-
// private predicate cipherNameMappingKnown(Crypto::TCipherType type, string name) {
94-
// name = "AES" and
95-
// type instanceof Crypto::AES
96-
// or
97-
// name = "DES" and
98-
// type instanceof Crypto::DES
99-
// or
100-
// name = "TripleDES" and
101-
// type instanceof Crypto::TripleDES
102-
// or
103-
// name = "IDEA" and
104-
// type instanceof Crypto::IDEA
105-
// or
106-
// name = "CAST5" and
107-
// type instanceof Crypto::CAST5
108-
// or
109-
// name = "ChaCha20" and
110-
// type instanceof Crypto::ChaCha20
111-
// or
112-
// name = "RC4" and
113-
// type instanceof Crypto::RC4
114-
// or
115-
// name = "RC5" and
116-
// type instanceof Crypto::RC5
117-
// or
118-
// name = "RSA" and
119-
// type instanceof Crypto::RSA
120-
// }
121-
// private predicate modeToNameMappingKnown(Crypto::TBlockCipherModeOperationType type, string name) {
122-
// type instanceof Crypto::ECB and name = "ECB"
123-
// or
124-
// type instanceof Crypto::CBC and name = "CBC"
125-
// or
126-
// type instanceof Crypto::GCM and name = "GCM"
127-
// or
128-
// type instanceof Crypto::CTR and name = "CTR"
129-
// or
130-
// type instanceof Crypto::XTS and name = "XTS"
131-
// or
132-
// type instanceof Crypto::CCM and name = "CCM"
133-
// or
134-
// type instanceof Crypto::SIV and name = "SIV"
135-
// or
136-
// type instanceof Crypto::OCB and name = "OCB"
137-
// }
138-
// override Crypto::TBlockCipherModeOperationType getModeType() {
139-
// if this.modeToNameMappingKnown(_, super.getMode())
140-
// then this.modeToNameMappingKnown(result, super.getMode())
141-
// else result instanceof Crypto::OtherMode
142-
// }
143-
// override string getRawModeAlgorithmName() { result = super.getMode() }
144-
// override string getRawPaddingAlgorithmName() { result = super.getPadding() }
145-
// bindingset[name]
146-
// private predicate paddingToNameMappingKnown(Crypto::TPaddingType type, string name) {
147-
// type instanceof Crypto::NoPadding and name = "NOPADDING"
148-
// or
149-
// type instanceof Crypto::PKCS7 and name = ["PKCS5Padding", "PKCS7Padding"] // TODO: misnomer in the JCA?
150-
// or
151-
// type instanceof Crypto::OAEP and name.matches("OAEP%") // TODO: handle OAEPWith%
152-
// }
153-
// }

0 commit comments

Comments
 (0)