Class CoseService


  • @ApplicationScoped
    public class CoseService
    extends Object
    Utility classes for COSE key structure.
    • Constructor Detail

      • CoseService

        public CoseService()
    • Method Detail

      • getCodeCurve

        public int getCodeCurve​(com.fasterxml.jackson.databind.JsonNode uncompressedECPointNode)
      • createUncompressedPointFromCOSEPublicKey

        public PublicKey createUncompressedPointFromCOSEPublicKey​(com.fasterxml.jackson.databind.JsonNode uncompressedECPointNode)
      • convertUncompressedPointToECKey

        public ECPublicKey convertUncompressedPointToECKey​(byte[] uncompressedPoint,
                                                           int curve)
      • getPublicKeyFromUncompressedECPoint

        public PublicKey getPublicKeyFromUncompressedECPoint​(byte[] uncompressedECPointCOSEPubKey)
      • convertECKeyToUncompressedPoint

        public com.fasterxml.jackson.databind.JsonNode convertECKeyToUncompressedPoint​(byte[] encodedPublicKey)
      • toUncompressedCoord

        public static byte[] toUncompressedCoord​(byte[] coord,
                                                 int keySizeBytes)
      • decodePublicKey

        public PublicKey decodePublicKey​(byte[] encodedPublicKey)
                                  throws io.jans.as.model.exception.SignatureException
        Throws:
        io.jans.as.model.exception.SignatureException