1. Project Clover database Sat Feb 2 2019 06:45:20 CET
  2. Package org.xwiki.crypto.pkix.params.x509certificate

File X509CertifiedPublicKey.java

 

Code metrics

0
0
0
1
84
17
0
-
-
0
-

Classes

Class Line # Actions
X509CertifiedPublicKey 34 0 - 0 0
-1.0 -
 

Contributing tests

No tests hitting this source file were found.

Source view

1    /*
2    * See the NOTICE file distributed with this work for additional
3    * information regarding copyright ownership.
4    *
5    * This is free software; you can redistribute it and/or modify it
6    * under the terms of the GNU Lesser General Public License as
7    * published by the Free Software Foundation; either version 2.1 of
8    * the License, or (at your option) any later version.
9    *
10    * This software is distributed in the hope that it will be useful,
11    * but WITHOUT ANY WARRANTY; without even the implied warranty of
12    * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13    * Lesser General Public License for more details.
14    *
15    * You should have received a copy of the GNU Lesser General Public
16    * License along with this software; if not, write to the Free
17    * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
18    * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
19    */
20    package org.xwiki.crypto.pkix.params.x509certificate;
21   
22    import java.math.BigInteger;
23    import java.util.Date;
24   
25    import org.xwiki.crypto.pkix.params.CertifiedPublicKey;
26    import org.xwiki.crypto.pkix.params.x509certificate.extension.X509Extensions;
27   
28    /**
29    * Certified binding of a principal to a public key using an X.509 Certificate.
30    *
31    * @version $Id: f8bc5f731ff68468b837f509be9698ff6c2ce400 $
32    * @since 5.4
33    */
 
34    public interface X509CertifiedPublicKey extends CertifiedPublicKey
35    {
36    /**
37    * @return the date after which this certificate is not valid.
38    */
39    Date getNotAfter();
40   
41    /**
42    * @return the date before which this certificate is not valid.
43    */
44    Date getNotBefore();
45   
46    /**
47    * @return the X.509 version of the certificate (1, 2 or 3).
48    */
49    int getVersionNumber();
50   
51    /**
52    * @return the serial number of the certificate.
53    */
54    BigInteger getSerialNumber();
55   
56    /**
57    * Check that the certificate is valid on the given date.
58    *
59    * @param date the date to be checked.
60    * @return true if the certificate is valid for the given date.
61    */
62    boolean isValidOn(Date date);
63   
64    /**
65    * @return true if this certificate is a CA certificate.
66    * @since 6.0M1
67    */
68    boolean isRootCA();
69   
70    /**
71    * @return X.509 extension.
72    */
73    X509Extensions getExtensions();
74   
75    /**
76    * @return the authority key identifier, or null of not available.
77    */
78    byte[] getAuthorityKeyIdentifier();
79   
80    /**
81    * @return the subject key identifier, or null of not available.
82    */
83    byte[] getSubjectKeyIdentifier();
84    }