@@ -36,18 +36,42 @@ public class Asn extends WolfObject {
3636 /* Key Sum values, from asn.h Key_Sum enum */
3737
3838 /** DSA key value, from asn.h Key_Sum enum */
39- public static final int DSAk = 515 ;
39+ public static final int DSAk ;
4040 /** RSA key value, from asn.h Key_Sum enum */
41- public static final int RSAk = 645 ;
41+ public static final int RSAk ;
4242 /** RSA-PSS key value, from asn.h Key_Sum enum */
43- public static final int RSAPSSk = 654 ;
43+ public static final int RSAPSSk ;
4444 /** RSA-OAEP key value, from asn.h Key_Sum enum */
45- public static final int RSAESOAEPk = 651 ;
45+ public static final int RSAESOAEPk ;
4646 /** ECDSA key value, from asn.h Key_Sum enum */
47- public static final int ECDSAk = 518 ;
47+ public static final int ECDSAk ;
48+
49+ static {
50+ DSAk = getDSAk ();
51+ RSAk = getRSAk ();
52+ RSAPSSk = getRSAPSSk ();
53+ RSAESOAEPk = getRSAESOAEPk ();
54+ ECDSAk = getECDSAk ();
55+ }
4856
4957 /** Default Asn constructor */
50- public Asn () { }
58+ public Asn () {
59+ }
60+
61+ /** Return value of native DSAk enum */
62+ private static native int getDSAk ();
63+
64+ /** Return value of native RSAk enum */
65+ private static native int getRSAk ();
66+
67+ /** Return value of native RSAPSSk enum */
68+ private static native int getRSAPSSk ();
69+
70+ /** Return value of native RSAESOAEPk enum */
71+ private static native int getRSAESOAEPk ();
72+
73+ /** Return value of native ECDSAk enum */
74+ private static native int getECDSAk ();
5175
5276 /** ASN.1 encode message digest, before it is signed
5377 *
0 commit comments