Skip to content

Cannot find signing scheme equivalent of "NONEwithRSA" in JAVA.Β #209

@swarupkm

Description

@swarupkm

Java security module has the below Signature algorithm support.

        String hash = "797c61b0a08a85da84ef59499fd26c3a44db9a718ba255423acae4407dc2948b";

        Signature sig = Signature.getInstance("NONEwithRSA");
        PrivateKey privateKey = getPrivateKey();
        sig.initSign(privateKey);
        sig.update(hash.getBytes());
        byte[] signedData = sig.sign();
        System.out.println(Base64.getEncoder().encodeToString(signedData));

Is there a way in Javascript to do its equivalent?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions