mirror of
https://github.com/github/codeql.git
synced 2026-04-20 14:34:04 +02:00
Getting rid of commented out code.
This commit is contained in:
@@ -80,74 +80,5 @@ class CipherKnownAlgorithmLiteralAlgorithmInstance extends Crypto::CipherAlgorit
|
||||
|
||||
override string getRawAlgorithmName() { result = this.(Literal).getValue().toString() }
|
||||
|
||||
override Crypto::TCipherType getCipherFamily() {
|
||||
literalToCipherFamilyType(this, result)
|
||||
}
|
||||
override Crypto::TCipherType getCipherFamily() { literalToCipherFamilyType(this, result) }
|
||||
}
|
||||
// override Crypto::TCipherType getCipherFamily() {
|
||||
// if this.cipherNameMappingKnown(_, super.getAlgorithmName())
|
||||
// then this.cipherNameMappingKnown(result, super.getAlgorithmName())
|
||||
// else result instanceof Crypto::OtherCipherType
|
||||
// }
|
||||
// bindingset[name]
|
||||
// private predicate cipherNameMappingKnown(Crypto::TCipherType type, string name) {
|
||||
// name = "AES" and
|
||||
// type instanceof Crypto::AES
|
||||
// or
|
||||
// name = "DES" and
|
||||
// type instanceof Crypto::DES
|
||||
// or
|
||||
// name = "TripleDES" and
|
||||
// type instanceof Crypto::TripleDES
|
||||
// or
|
||||
// name = "IDEA" and
|
||||
// type instanceof Crypto::IDEA
|
||||
// or
|
||||
// name = "CAST5" and
|
||||
// type instanceof Crypto::CAST5
|
||||
// or
|
||||
// name = "ChaCha20" and
|
||||
// type instanceof Crypto::ChaCha20
|
||||
// or
|
||||
// name = "RC4" and
|
||||
// type instanceof Crypto::RC4
|
||||
// or
|
||||
// name = "RC5" and
|
||||
// type instanceof Crypto::RC5
|
||||
// or
|
||||
// name = "RSA" and
|
||||
// type instanceof Crypto::RSA
|
||||
// }
|
||||
// private predicate modeToNameMappingKnown(Crypto::TBlockCipherModeOperationType type, string name) {
|
||||
// type instanceof Crypto::ECB and name = "ECB"
|
||||
// or
|
||||
// type instanceof Crypto::CBC and name = "CBC"
|
||||
// or
|
||||
// type instanceof Crypto::GCM and name = "GCM"
|
||||
// or
|
||||
// type instanceof Crypto::CTR and name = "CTR"
|
||||
// or
|
||||
// type instanceof Crypto::XTS and name = "XTS"
|
||||
// or
|
||||
// type instanceof Crypto::CCM and name = "CCM"
|
||||
// or
|
||||
// type instanceof Crypto::SIV and name = "SIV"
|
||||
// or
|
||||
// type instanceof Crypto::OCB and name = "OCB"
|
||||
// }
|
||||
// override Crypto::TBlockCipherModeOperationType getModeType() {
|
||||
// if this.modeToNameMappingKnown(_, super.getMode())
|
||||
// then this.modeToNameMappingKnown(result, super.getMode())
|
||||
// else result instanceof Crypto::OtherMode
|
||||
// }
|
||||
// override string getRawModeAlgorithmName() { result = super.getMode() }
|
||||
// override string getRawPaddingAlgorithmName() { result = super.getPadding() }
|
||||
// bindingset[name]
|
||||
// private predicate paddingToNameMappingKnown(Crypto::TPaddingType type, string name) {
|
||||
// type instanceof Crypto::NoPadding and name = "NOPADDING"
|
||||
// or
|
||||
// type instanceof Crypto::PKCS7 and name = ["PKCS5Padding", "PKCS7Padding"] // TODO: misnomer in the JCA?
|
||||
// or
|
||||
// type instanceof Crypto::OAEP and name.matches("OAEP%") // TODO: handle OAEPWith%
|
||||
// }
|
||||
// }
|
||||
|
||||
Reference in New Issue
Block a user