IPWorks Encrypt 2020 Android Edition

Questions / Feedback?

Algorithm Property

The algorithm used when signing.

Syntax

public int getAlgorithm();
public void setAlgorithm(int algorithm);

Enumerated values: public final static int jwsHS256 = 0; public final static int jwsHS384 = 1; public final static int jwsHS512 = 2; public final static int jwsRS256 = 3; public final static int jwsRS384 = 4; public final static int jwsRS512 = 5; public final static int jwsES256 = 6; public final static int jwsES384 = 7; public final static int jwsES512 = 8; public final static int jwsPS256 = 9; public final static int jwsPS384 = 10; public final static int jwsPS512 = 11; public final static int jwsNone = 12; public final static int jwsES256K = 13;

Remarks

This property specifies the algorithm to use when signing.

When signing with an HMAC algorithm Key must be specified. When an RSA or ECDSA algorithm is selected Certificate must be set before calling Sign and Certificate must be set before calling Verify. The following values are supported:

AlgorithmDescriptionPrivate Key Location
0 (jwsHS256 - default) HMAC using SHA-256 Key
1 (jwsHS384) HMAC using SHA-384 Key
2 (jwsHS512) HMAC using SHA-512 Key
3 (jwsRS256) RSASSA-PKCS1-v1_5 using SHA-256 Certificate
4 (jwsRS384) RSASSA-PKCS1-v1_5 using SHA-384 Certificate
5 (jwsRS512) RSASSA-PKCS1-v1_5 using SHA-512 Certificate
6 (jwsPS256) RSASSA-PSS using SHA-256 and MGF1 with SHA-256 Certificate
7 (jwsPS384) RSASSA-PSS using SHA-384 and MGF1 with SHA-384 Certificate
8 (jwsPS512) RSASSA-PSS using SHA-512 and MGF1 with SHA-512 Certificate
9 (jwsES256) ECDSA using P-256 and SHA-256 Certificate
10 (jwsES384) ECDSA using P-384 and SHA-384 Certificate
11 (jwsES512) ECDSA using P-521 and SHA-512 Certificate
12 (jwsNone) None (unprotected) Not Applicable
13 (jwsES256K) ECDSA using secp256k1 curve and SHA-256 Certificate

Note: This setting is also applicable when StrictValidation is enabled before calling Verify.

Default Value

0

Copyright (c) 2022 /n software inc. - All rights reserved.
IPWorks Encrypt 2020 Android Edition - Version 20.0 [Build 8161]