FileDocCategorySizeDatePackage
Support_ProviderTrust.javaAPI DocAndroid 1.5 API3234Wed May 06 22:41:06 BST 2009tests.support

Support_ProviderTrust

public class Support_ProviderTrust extends Provider
This class implements a dummy provider.

Fields Summary
private static final long
serialVersionUID
private static final String
NAME
private static final double
VERSION
private static final String
INFO
Constructors Summary
public Support_ProviderTrust()
Constructs a new instance of the dummy provider.


                  
      
        super(NAME, VERSION, INFO);
        registerServices();
    
Methods Summary
private voidregisterServices()
Register the services the receiver provides.

        AccessController.doPrivileged(new PrivilegedAction<Void>() {
            public Void run() {
                // Digest engine
                put("MessageDigest.SHA",
                        "made.up.provider.name.MessageDigestSHA");
                put("MessageDigest.MD5",
                        "made.up.provider.name.MessageDigestMD5");

                // Algorithm parameter generator
                put("AlgorithmParameterGenerator.DSA",
                        "made.up.provider.name.AlgorithmParameterGeneratorDSA");

                // Algorithm parameters
                put("AlgorithmParameters.DSA",
                        "made.up.provider.name.AlgorithmParametersDSA");

                // Key pair generator
                put("KeyPairGenerator.DSA",
                        "made.up.provider.name.KeyPairGeneratorDSA");

                // Key factory
                put("KeyFactory.DSA", "made.up.provider.name.KeyFactoryDSA");
                put("KeyFactory.RSA", "made.up.provider.name.KeyFactoryRSA");

                // Signature algorithm
                put("Signature.SHA1withDSA",
                        "made.up.provider.name.SignatureDSA");

                // KeyStore
                put("KeyStore.PKCS#12/Netscape",
                        "made.up.provider.name.KeyStore");

                // Certificate
                put("CertificateFactory.X509",
                        "made.up.provider.name.CertificateFactoryX509");

                return null;
            }
        });