Tabnine Logo
Association.createHmacSha256
Code IndexAdd Tabnine to your IDE (free)

How to use
createHmacSha256
method
in
org.openid4java.association.Association

Best Java code snippets using org.openid4java.association.Association.createHmacSha256 (Showing top 20 results out of 315)

origin: org.wso2.carbon.identity/org.wso2.carbon.identity.provider

  @Override
  public Association load(String handle) {

    if(IdentityUtil.isBlank(handle)){
      throw new IllegalArgumentException("Handle is empty");
    }
    if(log.isDebugEnabled()){
      log.debug("Inside load(); handle : " + handle);
    }
    String timeStamp = handle.substring((Integer.toString(storeId)).length(), handle.indexOf("-"));
    Date expireDate = new Date(Long.parseLong(timeStamp)+ this.expireIn);
    if(log.isDebugEnabled()){
      log.debug("Calculated Expiry Time : " + expireDate.getTime());
    }
//        SecretKeyFactory factory = SecretKeyFactory.getInstance("PBKDF2WithHmacSHA1");
//        PBEKeySpec spec = new PBEKeySpec(serverKey.toCharArray(), handle.getBytes(), 1, 256);
//        SecretKey secretKey = factory.generateSecret(spec);

    return Association.createHmacSha256(handle, (serverKey + handle).getBytes(), expireDate);
  }

origin: org.wso2.carbon.identity.inbound.auth.openid/org.wso2.carbon.identity.provider

  @Override
  public Association load(String handle) {

    if(IdentityUtil.isBlank(handle)){
      throw new IllegalArgumentException("Handle is empty");
    }
    if(log.isDebugEnabled()){
      log.debug("Inside load(); handle : " + handle);
    }
    String timeStamp = handle.substring((Integer.toString(storeId)).length(), handle.indexOf("-"));
    Date expireDate = new Date(Long.parseLong(timeStamp)+ this.expireIn);
    if(log.isDebugEnabled()){
      log.debug("Calculated Expiry Time : " + expireDate.getTime());
    }
//        SecretKeyFactory factory = SecretKeyFactory.getInstance("PBKDF2WithHmacSHA1");
//        PBEKeySpec spec = new PBEKeySpec(serverKey.toCharArray(), handle.getBytes(), 1, 256);
//        SecretKey secretKey = factory.generateSecret(spec);

    return Association.createHmacSha256(handle, (serverKey + handle).getBytes(), expireDate);
  }

origin: org.wso2.carbon.identity/org.wso2.carbon.identity.provider

Association association = Association.createHmacSha256(handle, (serverKey + handle).getBytes(), expireDate);
OpenIDServerManager.setThreadLocalAssociation(association);
return association;
origin: org.wso2.carbon.identity.inbound.auth.openid/org.wso2.carbon.identity.provider

Association association = Association.createHmacSha256(handle, (serverKey + handle).getBytes(), expireDate);
OpenIDServerManager.setThreadLocalAssociation(association);
return association;
origin: be.fedict.eid-idp/eid-idp-protocol-openid

  long exp = dataInputStream.readLong();
  Date expDate = new Date(exp);
  return Association.createHmacSha256(handle, macKeyBytes, expDate);
} else {
  return null;
origin: org.wso2.carbon.identity.inbound.auth.openid/org.wso2.carbon.identity.provider

assoc = Association.createHmacSha256(assocHandle, Base64.decode(macKey), expireIn);
origin: be.fedict.eid-idp/eid-idp-protocol-openid

  return Association.createHmacSha1(handle, macKeyBytes, expiry);
} else if (type == Association.TYPE_HMAC_SHA256) {
  return Association.createHmacSha256(handle, macKeyBytes, expiry);
origin: org.wso2.org.openid4java/openid4java-nodeps

                    Base64.decodeBase64(macKey.getBytes()), expDate);
} else if (Association.TYPE_HMAC_SHA256.equals(type)) {
  assoc = Association.createHmacSha256(handle,
                     Base64.decodeBase64(macKey.getBytes()), expDate);
} else {
origin: org.wso2.org.openid4java/openid4java-nodeps

assoc = Association.createHmacSha256(handle,
                   Base64.decodeBase64(macKey.getBytes()),
                   expDate);
origin: org.openid4java/openid4java-nodeps

assoc = Association.createHmacSha256(handle,
    Base64.decodeBase64(macKey.getBytes() ), expDate);
origin: com.cloudbees/openid4java-shaded

assoc = Association.createHmacSha256 (	handle,
                    Base64.decodeBase64 ( macKey.getBytes ( ) ),
                    expDate ) ;
origin: jbufu/openid4java

assoc = Association.createHmacSha256(handle,
    Base64.decodeBase64(macKey.getBytes() ), expDate);
origin: org.openid4java/openid4java-nodeps

assoc = Association.createHmacSha256 (	handle,
                    Base64.decodeBase64 ( macKey.getBytes ( ) ),
                    expDate ) ;
origin: org.wso2.org.openid4java/openid4java-nodeps

                    expDate);
} else if (Association.TYPE_HMAC_SHA256.equals(type)) {
  assoc = Association.createHmacSha256(handle,
                     Base64.decodeBase64(macKey.getBytes()),
                     expDate);
origin: jbufu/openid4java

assoc = Association.createHmacSha256 (	handle,
                    Base64.decodeBase64 ( macKey.getBytes ( ) ),
                    expDate ) ;
origin: com.cloudbees/openid4java-shaded

assoc = Association.createHmacSha256(handle,
    Base64.decodeBase64(macKey.getBytes() ), expDate);
origin: org.openid4java/openid4java

assoc = Association.createHmacSha256(handle, macKey, expiresIn);
origin: org.openid4java/openid4java-nodeps

assoc = Association.createHmacSha256(handle, macKey, expiresIn);
origin: com.cloudbees/openid4java-shaded

assoc = Association.createHmacSha256(handle, macKey, expiresIn);
origin: jbufu/openid4java

assoc = Association.createHmacSha256(handle, macKey, expiresIn);
org.openid4java.associationAssociationcreateHmacSha256

Popular methods of Association

  • getHandle
  • hasExpired
  • createHmacSha1
  • generate
  • getExpiry
  • getMacKey
  • getType
  • sign
  • verifySignature
  • <init>
  • createMacKey
  • generateHmacSha1
  • createMacKey,
  • generateHmacSha1,
  • generateHmacSha256,
  • generateMacKey,
  • generateMacSha1Key,
  • generateMacSha256Key,
  • getFailedAssociation,
  • isHmacSha256Supported,
  • isHmacSupported

Popular in Java

  • Finding current android device location
  • getResourceAsStream (ClassLoader)
  • requestLocationUpdates (LocationManager)
  • getExternalFilesDir (Context)
  • URI (java.net)
    A Uniform Resource Identifier that identifies an abstract or physical resource, as specified by RFC
  • Format (java.text)
    The base class for all formats. This is an abstract base class which specifies the protocol for clas
  • Vector (java.util)
    Vector is an implementation of List, backed by an array and synchronized. All optional operations in
  • Collectors (java.util.stream)
  • HttpServlet (javax.servlet.http)
    Provides an abstract class to be subclassed to create an HTTP servlet suitable for a Web site. A sub
  • Base64 (org.apache.commons.codec.binary)
    Provides Base64 encoding and decoding as defined by RFC 2045.This class implements section 6.8. Base
  • Best plugins for Eclipse
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyTerms of usePrivacy policyJava Code IndexJavascript Code Index
Get Tabnine for your IDE now