jdk/src/java.naming/share/classes/sun/security/provider/certpath/ldap/JdkLDAP.java
equal
deleted
inserted
replaced
25 |
25 |
26 package sun.security.provider.certpath.ldap; |
26 package sun.security.provider.certpath.ldap; |
27 |
27 |
28 import java.util.HashMap; |
28 import java.util.HashMap; |
29 import java.util.List; |
29 import java.util.List; |
30 import java.security.Provider; |
30 import java.security.*; |
31 import java.security.NoSuchAlgorithmException; |
|
32 import java.security.InvalidParameterException; |
|
33 import java.security.InvalidAlgorithmParameterException; |
|
34 import java.security.ProviderException; |
|
35 import java.security.cert.CertStoreParameters; |
31 import java.security.cert.CertStoreParameters; |
36 |
32 |
37 /** |
33 /** |
38 * Provider class for the JdkLDAP provider. |
34 * Provider class for the JdkLDAP provider. |
39 * Supports LDAP cert store. |
35 * Supports LDAP cert store. |
73 } |
69 } |
74 |
70 |
75 public JdkLDAP() { |
71 public JdkLDAP() { |
76 super("JdkLDAP", 1.9d, "JdkLDAP Provider (implements LDAP CertStore)"); |
72 super("JdkLDAP", 1.9d, "JdkLDAP Provider (implements LDAP CertStore)"); |
77 |
73 |
78 HashMap<String, String> attrs = new HashMap<>(2); |
74 final Provider p = this; |
79 attrs.put("LDAPSchema", "RFC2587"); |
75 AccessController.doPrivileged(new PrivilegedAction<Void>() { |
80 attrs.put("ImplementedIn", "Software"); |
76 public Void run() { |
|
77 HashMap<String, String> attrs = new HashMap<>(2); |
|
78 attrs.put("LDAPSchema", "RFC2587"); |
|
79 attrs.put("ImplementedIn", "Software"); |
81 |
80 |
82 /* |
81 /* |
83 * CertStore |
82 * CertStore |
84 * attrs: LDAPSchema, ImplementedIn |
83 * attrs: LDAPSchema, ImplementedIn |
85 */ |
84 */ |
86 putService(new ProviderService(this, "CertStore", |
85 putService(new ProviderService(p, "CertStore", |
87 "LDAP", "sun.security.provider.certpath.ldap.LDAPCertStore", |
86 "LDAP", "sun.security.provider.certpath.ldap.LDAPCertStore", |
88 null, attrs)); |
87 null, attrs)); |
|
88 return null; |
|
89 } |
|
90 }); |
89 } |
91 } |
90 } |
92 } |