org.openoces.ooapi.cert
Class PersonalOcesCertificateTest

java.lang.Object
  extended by junit.framework.Assert
      extended by junit.framework.TestCase
          extended by org.openoces.ooapi.cert.PersonalOcesCertificateTest
All Implemented Interfaces:
junit.framework.Test

public class PersonalOcesCertificateTest
extends junit.framework.TestCase


Field Summary
protected  PersonalOcesCertificate cPersonalNotRevoked
           
protected  PersonalOcesCertificate cPersonalPseudonym
           
protected  PersonalOcesCertificate cPersonalRevoked
           
protected  PersonalOcesCertificate cYouth
           
 
Constructor Summary
PersonalOcesCertificateTest()
           
 
Method Summary
protected  void setUp()
           
protected  void tearDown()
           
 void testConstruction()
           
 void testCRLDistributionPoints()
           
 void testExtractedSubjectDN()
           
 void testIsYouthCertificateNegative()
           
 void testIsYouthCertificatePositive()
           
 void testOcesIdExtraction()
           
 void testPersonalOcesIdExtraction()
           
 void testPersonalOcesIdExtractionYouthCase()
           
 void testPseudonymCNNegative()
           
 void testPseudonymCNPositive()
           
 void testSCSPSigningCapabilityNegative()
           
 void testVerificationOfRevokedCertificate()
           
 void testVerificationOfValidCertificate()
           
 void testVerificationOfYouthCertificate()
           
 
Methods inherited from class junit.framework.TestCase
countTestCases, createResult, getName, run, run, runBare, runTest, setName, toString
 
Methods inherited from class junit.framework.Assert
assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertFalse, assertFalse, assertNotNull, assertNotNull, assertNotSame, assertNotSame, assertNull, assertNull, assertSame, assertSame, assertTrue, assertTrue, fail, fail
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

cPersonalRevoked

protected PersonalOcesCertificate cPersonalRevoked

cPersonalNotRevoked

protected PersonalOcesCertificate cPersonalNotRevoked

cPersonalPseudonym

protected PersonalOcesCertificate cPersonalPseudonym

cYouth

protected PersonalOcesCertificate cYouth
Constructor Detail

PersonalOcesCertificateTest

public PersonalOcesCertificateTest()
Method Detail

testConstruction

public void testConstruction()
                      throws java.security.cert.CertificateException
Throws:
java.security.cert.CertificateException

testOcesIdExtraction

public void testOcesIdExtraction()
                          throws NonOcesCertificateException
Throws:
NonOcesCertificateException

testPersonalOcesIdExtraction

public void testPersonalOcesIdExtraction()
                                  throws NonOcesCertificateException
Throws:
NonOcesCertificateException

testIsYouthCertificateNegative

public void testIsYouthCertificateNegative()
                                    throws NonOcesCertificateException
Throws:
NonOcesCertificateException

testSCSPSigningCapabilityNegative

public void testSCSPSigningCapabilityNegative()
                                       throws NonOcesCertificateException,
                                              InternalException
Throws:
NonOcesCertificateException
InternalException

testIsYouthCertificatePositive

public void testIsYouthCertificatePositive()
                                    throws NonOcesCertificateException
Throws:
NonOcesCertificateException

testPersonalOcesIdExtractionYouthCase

public void testPersonalOcesIdExtractionYouthCase()
                                           throws NonOcesCertificateException
Throws:
NonOcesCertificateException

testVerificationOfYouthCertificate

public void testVerificationOfYouthCertificate()
                                        throws SignatureVerificationException,
                                               CertificateHasExpiredException,
                                               InternalException,
                                               CertificateIsNotYetValidException,
                                               CertificateRevokedException,
                                               CRLExpiredException,
                                               CRLNotYetValidException
Throws:
SignatureVerificationException
CertificateHasExpiredException
InternalException
CertificateIsNotYetValidException
CertificateRevokedException
CRLExpiredException
CRLNotYetValidException

testCRLDistributionPoints

public void testCRLDistributionPoints()
                               throws SignatureVerificationException,
                                      CertificateHasExpiredException,
                                      InternalException,
                                      CertificateIsNotYetValidException,
                                      CertificateRevokedException,
                                      CRLExpiredException,
                                      CRLNotYetValidException
Throws:
SignatureVerificationException
CertificateHasExpiredException
InternalException
CertificateIsNotYetValidException
CertificateRevokedException
CRLExpiredException
CRLNotYetValidException

testVerificationOfRevokedCertificate

public void testVerificationOfRevokedCertificate()
                                          throws SignatureVerificationException,
                                                 CertificateHasExpiredException,
                                                 InternalException,
                                                 CertificateIsNotYetValidException,
                                                 CRLExpiredException,
                                                 CRLNotYetValidException
Throws:
SignatureVerificationException
CertificateHasExpiredException
InternalException
CertificateIsNotYetValidException
CRLExpiredException
CRLNotYetValidException

testVerificationOfValidCertificate

public void testVerificationOfValidCertificate()
                                        throws SignatureVerificationException,
                                               CertificateHasExpiredException,
                                               InternalException,
                                               CertificateIsNotYetValidException,
                                               CRLExpiredException,
                                               CRLNotYetValidException,
                                               CertificateRevokedException
Throws:
SignatureVerificationException
CertificateHasExpiredException
InternalException
CertificateIsNotYetValidException
CRLExpiredException
CRLNotYetValidException
CertificateRevokedException

testPseudonymCNPositive

public void testPseudonymCNPositive()
                             throws NonOcesCertificateException
Throws:
NonOcesCertificateException

testPseudonymCNNegative

public void testPseudonymCNNegative()
                             throws NonOcesCertificateException
Throws:
NonOcesCertificateException

testExtractedSubjectDN

public void testExtractedSubjectDN()

setUp

protected void setUp()
              throws java.security.cert.CertificateException,
                     java.io.IOException,
                     java.security.cert.CRLException,
                     CRLExpiredException,
                     CRLNotYetValidException
Overrides:
setUp in class junit.framework.TestCase
Throws:
java.security.cert.CertificateException
java.io.IOException
java.security.cert.CRLException
CRLExpiredException
CRLNotYetValidException

tearDown

protected void tearDown()
Overrides:
tearDown in class junit.framework.TestCase