Example usage for java.security.spec PSSParameterSpec DEFAULT

List of usage examples for java.security.spec PSSParameterSpec DEFAULT

Introduction

In this page you can find the example usage for java.security.spec PSSParameterSpec DEFAULT.

Prototype

PSSParameterSpec DEFAULT

To view the source code for java.security.spec PSSParameterSpec DEFAULT.

Click Source Link

Document

The PSS parameter set with all default values

Usage

From source file:MainClass.java

public static void main(String[] args) throws Exception {
    Security.addProvider(new org.bouncycastle.jce.provider.BouncyCastleProvider());

    Signature signature = Signature.getInstance("SHA1withRSAandMGF1", "BC");
    signature.setParameter(PSSParameterSpec.DEFAULT);

    AlgorithmParameters params = signature.getParameters();

    ASN1InputStream aIn = new ASN1InputStream(params.getEncoded("ASN.1"));

    System.out.println(ASN1Dump.dumpAsString(aIn.readObject()));
}