Java Doc for PKIManager.java in  » 6.0-JDK-Modules » j2me » com » sun » satsa » pki » Java Source Code / Java DocumentationJava Source Code and Java Documentation

Java Source Code / Java Documentation
1. 6.0 JDK Core
2. 6.0 JDK Modules
3. 6.0 JDK Modules com.sun
4. 6.0 JDK Modules com.sun.java
5. 6.0 JDK Modules sun
6. 6.0 JDK Platform
7. Ajax
8. Apache Harmony Java SE
9. Aspect oriented
10. Authentication Authorization
11. Blogger System
12. Build
13. Byte Code
14. Cache
15. Chart
16. Chat
17. Code Analyzer
18. Collaboration
19. Content Management System
20. Database Client
21. Database DBMS
22. Database JDBC Connection Pool
23. Database ORM
24. Development
25. EJB Server geronimo
26. EJB Server GlassFish
27. EJB Server JBoss 4.2.1
28. EJB Server resin 3.1.5
29. ERP CRM Financial
30. ESB
31. Forum
32. GIS
33. Graphic Library
34. Groupware
35. HTML Parser
36. IDE
37. IDE Eclipse
38. IDE Netbeans
39. Installer
40. Internationalization Localization
41. Inversion of Control
42. Issue Tracking
43. J2EE
44. JBoss
45. JMS
46. JMX
47. Library
48. Mail Clients
49. Net
50. Parser
51. PDF
52. Portal
53. Profiler
54. Project Management
55. Report
56. RSS RDF
57. Rule Engine
58. Science
59. Scripting
60. Search Engine
61. Security
62. Sevlet Container
63. Source Control
64. Swing Library
65. Template Engine
66. Test Coverage
67. Testing
68. UML
69. Web Crawler
70. Web Framework
71. Web Mail
72. Web Server
73. Web Services
74. Web Services apache cxf 2.0.1
75. Web Services AXIS2
76. Wiki Engine
77. Workflow Engines
78. XML
79. XML UI
Java
Java Tutorial
Java Open Source
Jar File Download
Java Articles
Java Products
Java by API
Photoshop Tutorials
Maya Tutorials
Flash Tutorials
3ds-Max Tutorials
Illustrator Tutorials
GIMP Tutorials
C# / C Sharp
C# / CSharp Tutorial
C# / CSharp Open Source
ASP.Net
ASP.NET Tutorial
JavaScript DHTML
JavaScript Tutorial
JavaScript Reference
HTML / CSS
HTML CSS Reference
C / ANSI-C
C Tutorial
C++
C++ Tutorial
Ruby
PHP
Python
Python Tutorial
Python Open Source
SQL Server / T-SQL
SQL Server / T-SQL Tutorial
Oracle PL / SQL
Oracle PL/SQL Tutorial
PostgreSQL
SQL / MySQL
MySQL Tutorial
VB.Net
VB.Net Tutorial
Flash / Flex / ActionScript
VBA / Excel / Access / Word
XML
XML Tutorial
Microsoft Office PowerPoint 2007 Tutorial
Microsoft Office Excel 2007 Tutorial
Microsoft Office Word 2007 Tutorial
Java Source Code / Java Documentation » 6.0 JDK Modules » j2me » com.sun.satsa.pki 
Source Cross Reference  Class Diagram Java Document (Java Doc) 


java.lang.Object
   com.sun.satsa.pki.PKIManager

PKIManager
public class PKIManager (Code)
This class provides implementation of methods defined by javax.microedition.pki.UserCredentialManager and javax.microedition.securityservice.CMSMessageSignatureService classes.


Field Summary
final public static  intAUTHENTICATE_DATA
     Signature operation identifier.
final public static  intAUTHENTICATE_STRING
     Signature operation identifier.
final public static  intSIGN_STRING
     Signature operation identifier.


Method Summary
public static synchronized  booleanaddCredential(String certDisplayName, byte[] pkiPath, String uri)
     Adds a user certificate to a certificate store.
Parameters:
  certDisplayName - the user friendly name associated with thecertificate.
Parameters:
  pkiPath - the DER encoded PKIPath containing usercertificate and certificate authority certificates.
Parameters:
  uri - a URI that resolves to a X.509v3 certificate.
public static synchronized  byte[]generateCSR(String nameInfo, String algorithm, int keyLen, int keyUsage, String securityElementID, String securityElementPrompt, boolean forceKeyGen)
     Creates a DER encoded PKCS#10 certificate enrollment request.
Parameters:
  nameInfo - the distinguished name to be included in thePKCS#10 certificate signing request.
Parameters:
  algorithm - the Object Identifier (OID) for the public keyalgorithm to use.
Parameters:
  keyLen - the key length.
Parameters:
  keyUsage - the functionality for which the key is markedinside the security element.
Parameters:
  securityElementID - identifies the security element on whichthe key resides.
Parameters:
  securityElementPrompt - guides a user to insert the correctsecurity element, if a suitable security element is removable andnot detected.
Parameters:
  forceKeyGen - if set to true a new key MUST be generated.
public static  booleanremoveCredential(String certDisplayName, byte[] issuerAndSerialNumber, String securityElementID, String securityElementPrompt)
     Removes a certificate from a certificate store.
Parameters:
  certDisplayName - the user friendly name associated with thecertificate.
Parameters:
  issuerAndSerialNumber - the DER encoded ASN.1 structure thatcontains the certificate issuer and serial number.
Parameters:
  securityElementID - identifies the security element on whichthe key resides.
Parameters:
  securityElementPrompt - guides the user to insert thecorrect security element if the security element is removable andnot detected.
public static  byte[]sign(int action, byte[] data, String string, int options, String[] caNames, String securityElementPrompt)
     Generates a signature.
Parameters:
  action - type of signature operation.
Parameters:
  data - data to be signed or null
Parameters:
  string - string to be signed or null
Parameters:
  options - signature format options
Parameters:
  caNames - an array of Strings that contain the distinguishednames of trusted certification authorities.
Parameters:
  securityElementPrompt - guides a user to insert the correctsecurity element if the security element is removable and notdetected.

Field Detail
AUTHENTICATE_DATA
final public static int AUTHENTICATE_DATA(Code)
Signature operation identifier.



AUTHENTICATE_STRING
final public static int AUTHENTICATE_STRING(Code)
Signature operation identifier.



SIGN_STRING
final public static int SIGN_STRING(Code)
Signature operation identifier.





Method Detail
addCredential
public static synchronized boolean addCredential(String certDisplayName, byte[] pkiPath, String uri) throws UserCredentialManagerException(Code)
Adds a user certificate to a certificate store.
Parameters:
  certDisplayName - the user friendly name associated with thecertificate.
Parameters:
  pkiPath - the DER encoded PKIPath containing usercertificate and certificate authority certificates.
Parameters:
  uri - a URI that resolves to a X.509v3 certificate. true if successful
throws:
  UserCredentialManagerException - if an error occurs whileadding a user credential
throws:
  SecurityException - if a PIN is blocked due to an excessivenumber of incorrect PIN entries



generateCSR
public static synchronized byte[] generateCSR(String nameInfo, String algorithm, int keyLen, int keyUsage, String securityElementID, String securityElementPrompt, boolean forceKeyGen) throws UserCredentialManagerException, CMSMessageSignatureServiceException(Code)
Creates a DER encoded PKCS#10 certificate enrollment request.
Parameters:
  nameInfo - the distinguished name to be included in thePKCS#10 certificate signing request.
Parameters:
  algorithm - the Object Identifier (OID) for the public keyalgorithm to use.
Parameters:
  keyLen - the key length.
Parameters:
  keyUsage - the functionality for which the key is markedinside the security element.
Parameters:
  securityElementID - identifies the security element on whichthe key resides.
Parameters:
  securityElementPrompt - guides a user to insert the correctsecurity element, if a suitable security element is removable andnot detected.
Parameters:
  forceKeyGen - if set to true a new key MUST be generated. DER encoded PKCS#10 certificate enrollment request
throws:
  UserCredentialManagerException - if an error occurs whilegenerating the certificate request
throws:
  CMSMessageSignatureServiceException - if an error occurswhile signing the certificate request
throws:
  SecurityException - if a PIN is blocked due to an excessivenumber of incorrect PIN entries



removeCredential
public static boolean removeCredential(String certDisplayName, byte[] issuerAndSerialNumber, String securityElementID, String securityElementPrompt) throws UserCredentialManagerException(Code)
Removes a certificate from a certificate store.
Parameters:
  certDisplayName - the user friendly name associated with thecertificate.
Parameters:
  issuerAndSerialNumber - the DER encoded ASN.1 structure thatcontains the certificate issuer and serial number.
Parameters:
  securityElementID - identifies the security element on whichthe key resides.
Parameters:
  securityElementPrompt - guides the user to insert thecorrect security element if the security element is removable andnot detected. false if operation cancelled
throws:
  UserCredentialManagerException - ifan error occurs while removing the credential
throws:
  SecurityException - if a PIN is blocked due to an excessivenumber of incorrect PIN entries



sign
public static byte[] sign(int action, byte[] data, String string, int options, String[] caNames, String securityElementPrompt) throws CMSMessageSignatureServiceException, UserCredentialManagerException(Code)
Generates a signature.
Parameters:
  action - type of signature operation.
Parameters:
  data - data to be signed or null
Parameters:
  string - string to be signed or null
Parameters:
  options - signature format options
Parameters:
  caNames - an array of Strings that contain the distinguishednames of trusted certification authorities.
Parameters:
  securityElementPrompt - guides a user to insert the correctsecurity element if the security element is removable and notdetected. the DER encoded signature, null if the signaturegeneration was cancelled by the user before completion
throws:
  CMSMessageSignatureServiceException - if an error occursduring signature generation
throws:
  UserCredentialManagerException - if key not found
throws:
  SecurityException - if caller does not have permission



Methods inherited from java.lang.Object
public boolean equals(Object obj)(Code)(Java Doc)
final native public Class getClass()(Code)(Java Doc)
native public int hashCode()(Code)(Java Doc)
final native public void notify()(Code)(Java Doc)
final native public void notifyAll()(Code)(Java Doc)
public String toString()(Code)(Java Doc)
final native public void wait(long timeout) throws InterruptedException(Code)(Java Doc)
final public void wait(long timeout, int nanos) throws InterruptedException(Code)(Java Doc)
final public void wait() throws InterruptedException(Code)(Java Doc)

www.java2java.com | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.