@@ -124,12 +124,15 @@ private class SymmetricSink extends InsufficientKeySizeSink {
124124
125125// ********************** SINKS HELPER CLASSES & PREDICATES **********************
126126/** A call to a method that initializes a key generator. */
127- abstract class KeyGenInitMethodAccess extends MethodAccess {
127+ abstract private class KeyGenInitMethodAccess extends MethodAccess {
128128 /** Gets the `keysize` argument of this call. */
129129 Argument getKeySizeArg ( ) { result = this .getArgument ( 0 ) }
130130}
131131
132- /** A call to the `initialize` method declared in `java.security.KeyPairGenerator`. */
132+ /**
133+ * A call to the `initialize` method declared in `java.security.KeyPairGenerator`
134+ * or to the `init` method declared in `java.security.AlgorithmParameterGenerator`.
135+ */
133136private class AsymmetricInitMethodAccess extends KeyGenInitMethodAccess {
134137 AsymmetricInitMethodAccess ( ) {
135138 this .getMethod ( ) instanceof KeyPairGeneratorInitMethod or
@@ -143,11 +146,14 @@ private class SymmetricInitMethodAccess extends KeyGenInitMethodAccess {
143146}
144147
145148/** An instance of a key generator. */
146- abstract class KeyGeneratorObject extends CryptoAlgoSpec {
149+ abstract private class KeyGeneratorObject extends CryptoAlgoSpec {
147150 string getAlgoName ( ) { result = this .getAlgoSpec ( ) .( StringLiteral ) .getValue ( ) .toUpperCase ( ) }
148151}
149152
150- /** An instance of a `java.security.KeyPairGenerator`. */
153+ /**
154+ * An instance of a `java.security.KeyPairGenerator`
155+ * or of a `java.security.AlgorithmParameterGenerator`.
156+ */
151157private class AsymmetricKeyGenerator extends KeyGeneratorObject {
152158 AsymmetricKeyGenerator ( ) {
153159 this instanceof JavaSecurityKeyPairGenerator or
@@ -165,7 +171,7 @@ private class SymmetricKeyGenerator extends KeyGeneratorObject {
165171}
166172
167173/** An instance of an algorithm specification. */
168- abstract class AlgoSpec extends ClassInstanceExpr {
174+ abstract private class AlgoSpec extends ClassInstanceExpr {
169175 Argument getKeySizeArg ( ) { result = this .getArgument ( 0 ) }
170176}
171177
0 commit comments