[ 
https://issues.apache.org/jira/browse/CAMEL-21971?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Andrea Cosentino updated CAMEL-21971:
-------------------------------------
    Fix Version/s: 4.12.0

> camel-pqc - Provide default KeyPair and Signature
> -------------------------------------------------
>
>                 Key: CAMEL-21971
>                 URL: https://issues.apache.org/jira/browse/CAMEL-21971
>             Project: Camel
>          Issue Type: Improvement
>            Reporter: Federico Mariani
>            Assignee: Andrea Cosentino
>            Priority: Minor
>             Fix For: 4.12.0
>
>
> From a tooling and usability perspective, providing a set of default KeyPairs 
> and Signatures that can be easily configured on the endpoint would be nice.
> Right now, custom beans need to be created:
> {code:java}
>     @BindToRegistry("Keypair")
>     public KeyPair setKeyPair() throws NoSuchAlgorithmException, 
> NoSuchProviderException, InvalidAlgorithmParameterException {
>         KeyPairGenerator kpGen = KeyPairGenerator.getInstance("Picnic", 
> "BCPQC");
>         kpGen.initialize(PicnicParameterSpec.picnic3l5);
>         KeyPair kp = kpGen.generateKeyPair();
>         return kp;
>     }
>     @BindToRegistry("Signer")
>     public Signature getSigner() throws NoSuchAlgorithmException {
>         Signature mlDsa = Signature.getInstance("Picnic");
>         return mlDsa;
>     } {code}
> What about providing a default implementation for some (most used) signature 
> algorithms? adding a new Configuration 
> [https://github.com/apache/camel/blob/main/components/camel-pqc/src/main/java/org/apache/camel/component/pqc/PQCConfiguration.java#L29]
>  that takes a String as input and automagically configure the algorithm.
> The algs should be initizliazed only if/when used, and potentially, the same 
> instance should be reused on different endpoints.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

Reply via email to