/** * @return the bits corresponding to the role intented for the certificate * See Iso7816CertificateHolderAuthorization static int for values * @throws IOException */ public int getHolderAuthorizationRole() throws IOException { int rights = certificateBody.getCertificateHolderAuthorization().getAccessRights(); return rights & 0xC0; }
/** * @return the Holder authorization and role (CVCA, DV, IS). */ public ASN1ObjectIdentifier getHolderAuthorization() throws IOException { CertificateHolderAuthorization cha = certificateBody.getCertificateHolderAuthorization(); return cha.getOid(); }
/** * create an Iso7816CertificateHolderAuthorization according to the parameters * * @param oid Object Identifier : specifies the format and the rules for the * evaluatioin of the authorization level. * @param rights specifies the access rights * @throws IOException */ public CertificateHolderAuthorization(ASN1ObjectIdentifier oid, int rights) throws IOException { setOid(oid); setAccessRights((byte)rights); }
/** * create an Iso7816CertificateHolderAuthorization according to the {@link DERApplicationSpecific} * * @param aSpe the DERApplicationSpecific containing the data * @throws IOException */ public CertificateHolderAuthorization(DERApplicationSpecific aSpe) throws IOException { if (aSpe.getApplicationTag() == EACTags.CERTIFICATE_HOLDER_AUTHORIZATION_TEMPLATE) { setPrivateData(new ASN1InputStream(aSpe.getContents())); } }
break; case EACTags.CERTIFICATE_HOLDER_AUTHORIZATION_TEMPLATE: setCertificateHolderAuthorization(new CertificateHolderAuthorization(aSpe)); break; case EACTags.APPLICATION_EFFECTIVE_DATE:
/** * create an Iso7816CertificateHolderAuthorization according to the {@link ASN1ApplicationSpecific} * * @param aSpe the DERApplicationSpecific containing the data * @throws IOException */ public CertificateHolderAuthorization(ASN1ApplicationSpecific aSpe) throws IOException { if (aSpe.getApplicationTag() == EACTags.CERTIFICATE_HOLDER_AUTHORIZATION_TEMPLATE) { setPrivateData(new ASN1InputStream(aSpe.getContents())); } }
break; case EACTags.CERTIFICATE_HOLDER_AUTHORIZATION_TEMPLATE: setCertificateHolderAuthorization(new CertificateHolderAuthorization(aSpe)); break; case EACTags.APPLICATION_EFFECTIVE_DATE:
/** * create an Iso7816CertificateHolderAuthorization according to the parameters * * @param oid Object Identifier : specifies the format and the rules for the * evaluatioin of the authorization level. * @param rights specifies the access rights * @throws IOException */ public CertificateHolderAuthorization(ASN1ObjectIdentifier oid, int rights) throws IOException { setOid(oid); setAccessRights((byte)rights); }
/** * @return the bits corresponding to the role intented for the certificate * See Iso7816CertificateHolderAuthorization static int for values * @throws IOException */ public int getHolderAuthorizationRole() throws IOException { int rights = certificateBody.getCertificateHolderAuthorization().getAccessRights(); return rights & 0xC0; }
/** * @return the Holder authorization and role (CVCA, DV, IS). */ public ASN1ObjectIdentifier getHolderAuthorization() throws IOException { CertificateHolderAuthorization cha = certificateBody.getCertificateHolderAuthorization(); return cha.getOid(); }
/** * return a bits field coded on one byte. For signification of the * several bit see Iso7816CertificateHolderAuthorization * * @return role and access rigth * @throws IOException * @see CertificateHolderAuthorization */ public int getRole() throws IOException { CertificateHolderAuthorization cha = certificateBody.getCertificateHolderAuthorization(); return cha.getAccessRights(); }
/** * return a bits field coded on one byte. For signification of the * several bit see Iso7816CertificateHolderAuthorization * * @return role and access rigth * @throws IOException * @see CertificateHolderAuthorization */ public int getRole() throws IOException { CertificateHolderAuthorization cha = certificateBody.getCertificateHolderAuthorization(); return cha.getAccessRights(); }
/** * @return the bits corresponding the authorizations contained in the certificate * See Iso7816CertificateHolderAuthorization static int for values * @throws IOException */ public Flags getHolderAuthorizationRights() throws IOException { return new Flags(certificateBody.getCertificateHolderAuthorization().getAccessRights() & 0x1F); } }
/** * @return the bits corresponding the authorizations contained in the certificate * See Iso7816CertificateHolderAuthorization static int for values * @throws IOException */ public Flags getHolderAuthorizationRights() throws IOException { return new Flags(certificateBody.getCertificateHolderAuthorization().getAccessRights() & 0x1F); } }