From d27f2f57274810f25520f835c7c68e612428d6f5 Mon Sep 17 00:00:00 2001 From: Arijit429 Date: Sat, 23 May 2026 09:35:44 +0530 Subject: [PATCH] fix: use withoutParameters() for Ed25519 and Ed448 generate rules to prevent false positives Signed-off-by: Arijit429 --- .../com/ibm/plugin/rules/detection/asymmetric/PycaSign.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/python/src/main/java/com/ibm/plugin/rules/detection/asymmetric/PycaSign.java b/python/src/main/java/com/ibm/plugin/rules/detection/asymmetric/PycaSign.java index 5a038c310..c60328630 100644 --- a/python/src/main/java/com/ibm/plugin/rules/detection/asymmetric/PycaSign.java +++ b/python/src/main/java/com/ibm/plugin/rules/detection/asymmetric/PycaSign.java @@ -43,7 +43,7 @@ private PycaSign() { "cryptography.hazmat.primitives.asymmetric.ed25519.Ed25519PrivateKey") .forMethods("generate") .shouldBeDetectedAs(new KeyActionFactory<>(KeyAction.Action.GENERATION)) - .withAnyParameters() + .withoutParameters() .buildForContext(new PrivateKeyContext(Map.of("algorithm", "Ed25519"))) .inBundle(() -> "Pyca") .withoutDependingDetectionRules(); @@ -55,7 +55,7 @@ private PycaSign() { "cryptography.hazmat.primitives.asymmetric.ed448.Ed448PrivateKey") .forMethods("generate") .shouldBeDetectedAs(new KeyActionFactory<>(KeyAction.Action.GENERATION)) - .withAnyParameters() + .withoutParameters() .buildForContext(new PrivateKeyContext(Map.of("algorithm", "Ed448"))) .inBundle(() -> "Pyca") .withoutDependingDetectionRules();