@@ -28,33 +28,6 @@ module InsecureFeatureFlag {
2828 override string getAFlagName ( ) { result .regexpMatch ( "(?i).*(secure|(en|dis)able).*" ) }
2929 }
3030
31- /**
32- * Flags suggesting support for an old or legacy TLS version.
33- *
34- * We accept 'intermediate' because it appears to be common for TLS users
35- * to define three profiles: modern, intermediate, legacy/old, perhaps based
36- * on https://wiki.mozilla.org/Security/Server_Side_TLS (though note the
37- * 'intermediate' used there would now pass muster according to this query)
38- */
39- class LegacyTlsVersionFlag extends FlagKind {
40- LegacyTlsVersionFlag ( ) { this = "legacyTlsVersion" }
41-
42- bindingset [ result ]
43- override string getAFlagName ( ) { result .regexpMatch ( "(?i).*(old|intermediate|legacy).*" ) }
44- }
45-
46- /**
47- * Flags suggesting a deliberately insecure certificate setup.
48- */
49- class InsecureCertificateFlag extends FlagKind {
50- InsecureCertificateFlag ( ) { this = "insecureCertificate" }
51-
52- bindingset [ result ]
53- override string getAFlagName ( ) {
54- result .regexpMatch ( "(?i).*(selfCert|selfSign|validat|verif|trust).*" )
55- }
56- }
57-
5831 /** Gets a global value number representing a (likely) security flag. */
5932 GVN getAFlag ( FlagKind flagKind ) {
6033 // a call like `cfg.disableVerification()`
@@ -142,18 +115,4 @@ module InsecureFeatureFlag {
142115 ControlFlow:: ConditionGuardNode getASecurityFeatureFlagCheck ( ) {
143116 result .ensures ( getAFlag ( any ( SecurityFeatureFlag f ) ) .getANode ( ) , _)
144117 }
145-
146- /**
147- * Gets a control-flow node that represents a (likely) flag controlling TLS version selection.
148- */
149- ControlFlow:: ConditionGuardNode getALegacyTlsVersionCheck ( ) {
150- result .ensures ( getAFlag ( any ( LegacyTlsVersionFlag f ) ) .getANode ( ) , _)
151- }
152-
153- /**
154- * Gets a control-flow node that represents a (likely) flag controlling an insecure certificate setup.
155- */
156- ControlFlow:: ConditionGuardNode getAnInsecureCertificateCheck ( ) {
157- result .ensures ( getAFlag ( any ( InsecureCertificateFlag f ) ) .getANode ( ) , _)
158- }
159118}
0 commit comments