|
Framework Professional Edition Package |
||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
public interface CertificateManager
This interface provides methods for manipulating certificate chains of bundles. It internally validates the certificates against a repository with trusted certificates.
| Method Summary | |
|---|---|
java.util.Vector |
getCerts(java.io.InputStream is)
Retrieves the certificates of the jar file, specified as an InputStream. |
java.lang.Object |
getCerts(long bid)
Returns the CertificateChain of the specified bundle's jar as Vector of encoded Certificate objects, which
are obtained through a call to JarEntry.getCertificates(). |
WriteableCertificateStorage |
getStorage()
Returns the WriteableCertificateStorage implementation, or null if this functionality is not supported. |
java.lang.String[] |
getSubjectDNs()
Returns the subject DNs for those certificates in the database, which has not expired yet. |
java.lang.String[][] |
getTrustedCertChainsInfo(java.lang.Object certs)
The parameter is an array of certificates, which is retrieved through JarEntry.getCertificates(). |
java.lang.String[][] |
getTrustedCerts(long bid)
Returns the trusted CertificateChain-s of the specified bundle's jar. |
boolean |
isCertPresentInDB(java.lang.Object certificate)
This method returns true if the following conditions are both true: a)the specified certificate is present in the database b)the certificate is not expired |
boolean |
isCertTrustedBySomeCertInDB(java.lang.Object certificate)
This method returns true if the following conditions are both true: a)the specified certificate is signed by another certificate which is present in the database b)the certificate is not expired |
boolean |
isTrustedCertChain(java.lang.Object certs)
Returs true if the following conditions for the specified certs are met:
a) it is a valid certificate chain
b) it is valid i.e. |
boolean |
matchDNChain(Bundle b,
java.lang.String pattern)
Checks whether the certificates of the specified bundle match the specified pattern. |
| Method Detail |
|---|
boolean isTrustedCertChain(java.lang.Object certs)
certs are met:
a) it is a valid certificate chain
b) it is valid i.e. all certificates has not expired
c) it is trusted i.e. a certificate from the chain is present in the repository
certs - certificate chain to check
java.util.Vector getCerts(java.io.InputStream is)
throws java.io.IOException
null if and only if the bundle is unsigned or
not signed according to the OSGi specification.
is - InputStream to a jar file
java.io.IOExceptionjava.lang.String[][] getTrustedCertChainsInfo(java.lang.Object certs)
certs - - are the result from calling JarEntry.getCertificates().
It should be an array of X509Certificate elements.
boolean isCertPresentInDB(java.lang.Object certificate)
certificate -
boolean isCertTrustedBySomeCertInDB(java.lang.Object certificate)
certificate -
java.lang.String[] getSubjectDNs()
java.lang.Object getCerts(long bid)
Vector of encoded Certificate objects, which
are obtained through a call to JarEntry.getCertificates().
If the jar is unsigned or is not signed properly, null is returned.
bid - specifies the bundle
java.lang.String[][] getTrustedCerts(long bid)
bid - specifies the bundle
boolean matchDNChain(Bundle b,
java.lang.String pattern)
b - pattern -
WriteableCertificateStorage getStorage()
|
Framework Professional Edition Package |
||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||