diff options
author | Matthew Harmsen <mharmsen@redhat.com> | 2016-12-09 15:29:50 -0700 |
---|---|---|
committer | Matthew Harmsen <mharmsen@redhat.com> | 2016-12-09 15:29:50 -0700 |
commit | 6cf7cec3c559786b90dcca298a2d7c6c570eac35 (patch) | |
tree | 93bf6ad73228716a1fb106affb9336593d88f6f6 /base/ca/shared | |
parent | ae350a3d4e0ae9b82fa44ebdfa37654f0083b4c1 (diff) | |
download | pki-6cf7cec3c559786b90dcca298a2d7c6c570eac35.tar.gz pki-6cf7cec3c559786b90dcca298a2d7c6c570eac35.tar.xz pki-6cf7cec3c559786b90dcca298a2d7c6c570eac35.zip |
Removed all references to 'xenroll.dll'
- PKI TRAC Ticket #2524 - Remove xenroll.dll from pki-core
Diffstat (limited to 'base/ca/shared')
23 files changed, 164 insertions, 578 deletions
diff --git a/base/ca/shared/webapps/ca/admin/ca/EnrollSuccess.template b/base/ca/shared/webapps/ca/admin/ca/EnrollSuccess.template index d3709831e..80c63322d 100644 --- a/base/ca/shared/webapps/ca/admin/ca/EnrollSuccess.template +++ b/base/ca/shared/webapps/ca/admin/ca/EnrollSuccess.template @@ -186,12 +186,6 @@ if (navigator.appName == 'Netscape' && </SCRIPT> -<OBJECT - classid="clsid:127698e4-e730-4e5c-a2b1-21490a70c8a1" - CODEBASE="/xenroll.dll" - id=Enroll > -</OBJECT> - <SCRIPT LANGUAGE=VBS> <!-- '======================================================== @@ -236,7 +230,6 @@ if (navigator.appName == 'Netscape' && End Sub ImportCertificate() - </SCRIPT> </font> diff --git a/base/ca/shared/webapps/ca/admin/ca/ImportAdminCert.template b/base/ca/shared/webapps/ca/admin/ca/ImportAdminCert.template index e52764ec6..5d1015424 100644 --- a/base/ca/shared/webapps/ca/admin/ca/ImportAdminCert.template +++ b/base/ca/shared/webapps/ca/admin/ca/ImportAdminCert.template @@ -21,10 +21,6 @@ <TITLE>VBScript Administrator Certificate Enrollment </TITLE> <CMS_TEMPLATE> -<OBJECT classid="clsid:127698E4-E730-4E5C-A2b1-21490A70C8A1" - codebase="xenroll.dll" - id=Enroll > -</OBJECT> <SCRIPT language="VBScript"> <!-- Dim pkcs7 diff --git a/base/ca/shared/webapps/ca/admin/ca/ImportCert.template b/base/ca/shared/webapps/ca/admin/ca/ImportCert.template index 5530cf2d1..bb644ed9e 100644 --- a/base/ca/shared/webapps/ca/admin/ca/ImportCert.template +++ b/base/ca/shared/webapps/ca/admin/ca/ImportCert.template @@ -135,12 +135,6 @@ if (navigator.appName == 'Netscape' && (navMajorVersion() > 3) && </SCRIPT> <!-- -<OBJECT - classid="clsid:127698e4-e730-4e5c-a2b1-21490a70c8a1" - CODEBASE="/xenroll.dll" - id=Enroll > -</OBJECT> - <OBJECT id='g_objClassFactory' CLASSID='clsid:884e2049-217d-11da-b2a4-000e7bbb2b09'> </OBJECT> --> @@ -148,11 +142,7 @@ if (navigator.appName == 'Netscape' && (navMajorVersion() > 3) && <SCRIPT LANGUAGE="JavaScript"> //<!-- if (navigator.appName == "Microsoft Internet Explorer") { - if ((navigator.appVersion).indexOf("NT 6.") > -1) { - document.writeln("<OBJECT id='g_objClassFactory' CLASSID='clsid:884e2049-217d-11da-b2a4-000e7bbb2b09'></OBJECT>"); - } else { - document.writeln("<OBJECT classid='clsid:127698e4-e730-4e5c-a2b1-21490a70c8a1' CODEBASE='/xenroll.dll' id='Enroll'></OBJECT>"); - } + document.writeln("<OBJECT id='g_objClassFactory' CLASSID='clsid:884e2049-217d-11da-b2a4-000e7bbb2b09'></OBJECT>"); } //--> </SCRIPT> @@ -168,38 +158,12 @@ if (navigator.appName == "Microsoft Internet Explorer") { ' '======================================================== - 'Get OS Version, works for Vista and below only - Function GetOSVersion - dim agent - dim res - dim pos - - agent = Navigator.appVersion - pos = InStr(agent,"NT 6.") - - If pos > 0 Then - GetOSVersion = 6 - Exit Function - End If - - pos = InStr(agent,"NT 5.") - - If pos > 0 Then - GetOSVersion = 5 - Exit Function - End If - - GetOSVersion = 5 - End Function - 'Sub ImportCertificate Sub ImportCertificate (pkcs7) 'Dim pkcs7 Dim res - Dim osVersion On Error Resume Next - osVersion = GetOSVersion() 'Convert the cert to PKCS7 format 'pkcs7 = result.header.pkcs7ChainBase64 @@ -209,42 +173,22 @@ if (navigator.appName == "Microsoft Internet Explorer") { Exit Sub End If - If osVersion <> 6 Then 'Not Vista - - 'Import the PKCS7 object - Enroll.DeleteRequestCert = FALSE - Enroll.WriteCertToCSP = true - Enroll.acceptPKCS7(pkcs7) - if err.number <> 0 then - Enroll.WriteCertToCSP = false - end if - err.clear - Enroll.acceptPKCS7(pkcs7) - if err.number = 0 then - MsgBox "Certificate has been successfully imported." - else - sz = "Error in acceptPKCS7. Error Number " & Hex(err.number) & "occurred." - MsgBox sz - end if - Exit Sub - Else 'Vista - Dim enrollObj - - Set enrollObj = g_objClassFactory.CreateObject("X509Enrollment.CX509Enrollment") - If IsObject(enrollObj) = False Then - res = MsgBox("Can't create Enroll Object!") - Exit Sub - End If - - enrollObj.Initialize(1) - enrollObj.InstallResponse 0,pkcs7,6,"" - - If Err.number <> 0 Then - sz = "Error in InstallResponse. Error Number " & Hex(err.number) & " occurred." - res =MsgBox(sz & Err.description) - else - res = MsgBox("Certificate has been successfully imported.") - End If + Dim enrollObj + + Set enrollObj = g_objClassFactory.CreateObject("X509Enrollment.CX509Enrollment") + IsObject(enrollObj) = False Then + res = MsgBox("Can't create Enroll Object!") + Exit Sub + End If + + enrollObj.Initialize(1) + enrollObj.InstallResponse 0,pkcs7,6,"" + + If Err.number <> 0 Then + sz = "Error in InstallResponse. Error Number " & Hex(err.number) & " occurred." + res =MsgBox(sz & Err.description) + else + res = MsgBox("Certificate has been successfully imported.") End If End Sub diff --git a/base/ca/shared/webapps/ca/admin/ca/adminEnroll.html b/base/ca/shared/webapps/ca/admin/ca/adminEnroll.html index 8b6335ab5..a08d462fe 100644 --- a/base/ca/shared/webapps/ca/admin/ca/adminEnroll.html +++ b/base/ca/shared/webapps/ca/admin/ca/adminEnroll.html @@ -96,13 +96,6 @@ function setCRMFRequest() </SCRIPT> </head> -<OBJECT - classid="clsid:127698e4-e730-4e5c-a2b1-21490a70c8a1" - CODEBASE="/xenroll.dll" - id=Enroll > -</OBJECT> - - <SCRIPT LANGUAGE=VBS> <!-- Function escapeDNComponent(comp) diff --git a/base/ca/shared/webapps/ca/agent/ca/EnrollSuccess.template b/base/ca/shared/webapps/ca/agent/ca/EnrollSuccess.template index 08bcd5240..44aecd152 100644 --- a/base/ca/shared/webapps/ca/agent/ca/EnrollSuccess.template +++ b/base/ca/shared/webapps/ca/agent/ca/EnrollSuccess.template @@ -160,12 +160,6 @@ if (navigator.appName == 'Netscape' && </SCRIPT> -<OBJECT - classid="clsid:127698e4-e730-4e5c-a2b1-21490a70c8a1" - CODEBASE="/xenroll.dll" - id=Enroll > -</OBJECT> - <SCRIPT LANGUAGE=VBS> <!-- '======================================================== diff --git a/base/ca/shared/webapps/ca/agent/ca/ImportCert.template b/base/ca/shared/webapps/ca/agent/ca/ImportCert.template index 37ad258c0..33a144460 100644 --- a/base/ca/shared/webapps/ca/agent/ca/ImportCert.template +++ b/base/ca/shared/webapps/ca/agent/ca/ImportCert.template @@ -132,22 +132,10 @@ if (navigator.appName == 'Netscape' && (navMajorVersion() > 3) && //--> </SCRIPT> -<!-- -<OBJECT - classid="clsid:127698e4-e730-4e5c-a2b1-21490a70c8a1" - CODEBASE="/xenroll.dll" - id=Enroll > -</OBJECT> ---> - <SCRIPT LANGUAGE="JavaScript"> //<!-- if (navigator.appName == "Microsoft Internet Explorer") { - if ((navigator.appVersion).indexOf("NT 6.") > -1) { - document.writeln("<OBJECT id='g_objClassFactory' CLASSID='clsid:884e2049-217d-11da-b2a4-000e7bbb2b09'></OBJECT>"); - } else { - document.writeln("<OBJECT classid='clsid:127698e4-e730-4e5c-a2b1-21490a70c8a1' CODEBASE='/xenroll.dll' id='Enroll'></OBJECT>"); - } + document.writeln("<OBJECT id='g_objClassFactory' CLASSID='clsid:884e2049-217d-11da-b2a4-000e7bbb2b09'></OBJECT>"); } //--> </SCRIPT> @@ -163,38 +151,12 @@ if (navigator.appName == "Microsoft Internet Explorer") { ' '======================================================== - 'Get OS Version, works for Vista and below only - Function GetOSVersion - dim agent - dim res - dim pos - - agent = Navigator.appVersion - pos = InStr(agent,"NT 6.") - - If pos > 0 Then - GetOSVersion = 6 - Exit Function - End If - - pos = InStr(agent,"NT 5.") - - If pos > 0 Then - GetOSVersion = 5 - Exit Function - End If - - GetOSVersion = 5 - End Function - 'Sub ImportCertificate Sub ImportCertificate (pkcs7) 'Dim pkcs7 Dim res - Dim osVersion On Error Resume Next - osVersion = GetOSVersion() 'Convert the cert to PKCS7 format 'pkcs7 = result.header.pkcs7ChainBase64 @@ -204,42 +166,22 @@ if (navigator.appName == "Microsoft Internet Explorer") { Exit Sub End If - If osVersion <> 6 Then 'Not Vista - - 'Import the PKCS7 object - Enroll.DeleteRequestCert = FALSE - Enroll.WriteCertToCSP = true - Enroll.acceptPKCS7(pkcs7) - if err.number <> 0 then - Enroll.WriteCertToCSP = false - end if - err.clear - Enroll.acceptPKCS7(pkcs7) - if err.number = 0 then - MsgBox "Certificate has been successfully imported." - else - sz = "Error in acceptPKCS7. Error Number " & Hex(err.number) & "occurred." - MsgBox sz - end if - Exit Sub - Else 'Vista - Dim enrollObj - - Set enrollObj = g_objClassFactory.CreateObject("X509Enrollment.CX509Enrollment") - If IsObject(enrollObj) = False Then - res = MsgBox("Can't create Enroll Object!") - Exit Sub - End If - - enrollObj.Initialize(1) - enrollObj.InstallResponse 0,pkcs7,6,"" - - If Err.number <> 0 Then - sz = "Error in InstallResponse. Error Number " & Hex(err.number) & " occurred." - res =MsgBox(sz & Err.description) - else - res = MsgBox("Certificate has been successfully imported.") - End If + Dim enrollObj + + Set enrollObj = g_objClassFactory.CreateObject("X509Enrollment.CX509Enrollment") + If IsObject(enrollObj) = False Then + res = MsgBox("Can't create Enroll Object!") + Exit Sub + End If + + enrollObj.Initialize(1) + enrollObj.InstallResponse 0,pkcs7,6,"" + + If Err.number <> 0 Then + sz = "Error in InstallResponse. Error Number " & Hex(err.number) & " occurred." + res =MsgBox(sz & Err.description) + else + res = MsgBox("Certificate has been successfully imported.") End If End Sub diff --git a/base/ca/shared/webapps/ca/agent/ca/displayBySerial.template b/base/ca/shared/webapps/ca/agent/ca/displayBySerial.template index e02fe30eb..0c7a90493 100644 --- a/base/ca/shared/webapps/ca/agent/ca/displayBySerial.template +++ b/base/ca/shared/webapps/ca/agent/ca/displayBySerial.template @@ -214,12 +214,6 @@ if (result.header.noCertImport != null && result.header.noCertImport == false) { //--> </SCRIPT> -<OBJECT - classid="clsid:127698e4-e730-4e5c-a2b1-21490a70c8a1" - CODEBASE="/xenroll.dll" - id=Enroll > -</OBJECT> - <SCRIPT LANGUAGE=VBS> <!-- '======================================================== diff --git a/base/ca/shared/webapps/ca/agent/xenroll.dll b/base/ca/shared/webapps/ca/agent/xenroll.dll Binary files differdeleted file mode 100644 index 9375e988d..000000000 --- a/base/ca/shared/webapps/ca/agent/xenroll.dll +++ /dev/null diff --git a/base/ca/shared/webapps/ca/ee/ca/AIMEnroll.html b/base/ca/shared/webapps/ca/ee/ca/AIMEnroll.html index 79862b377..4b14a8b5c 100644 --- a/base/ca/shared/webapps/ca/ee/ca/AIMEnroll.html +++ b/base/ca/shared/webapps/ca/ee/ca/AIMEnroll.html @@ -26,13 +26,6 @@ <SCRIPT LANGUAGE="JavaScript" SRC="/ca/ee/dynamicVars.js"> </SCRIPT> </head> -<OBJECT - classid="clsid:127698e4-e730-4e5c-a2b1-21490a70c8a1" - CODEBASE="/ee/xenroll.dll" - id=Enroll > -</OBJECT> - - <SCRIPT LANGUAGE=VBS> <!-- Function escapeDNComponent(comp) diff --git a/base/ca/shared/webapps/ca/ee/ca/CertBasedDualEnroll.html b/base/ca/shared/webapps/ca/ee/ca/CertBasedDualEnroll.html index 05d672f37..9e37706e7 100644 --- a/base/ca/shared/webapps/ca/ee/ca/CertBasedDualEnroll.html +++ b/base/ca/shared/webapps/ca/ee/ca/CertBasedDualEnroll.html @@ -48,13 +48,6 @@ function validate(form) </SCRIPT> </head> -<OBJECT - classid="clsid:127698e4-e730-4e5c-a2b1-21490a70c8a1" - CODEBASE="/ee/xenroll.dll" - id=Enroll > -</OBJECT> - - <SCRIPT LANGUAGE=VBS> <!-- Function escapeDNComponent(comp) diff --git a/base/ca/shared/webapps/ca/ee/ca/CertBasedEncryptionEnroll.html b/base/ca/shared/webapps/ca/ee/ca/CertBasedEncryptionEnroll.html index 67cb0cbdb..466447c31 100644 --- a/base/ca/shared/webapps/ca/ee/ca/CertBasedEncryptionEnroll.html +++ b/base/ca/shared/webapps/ca/ee/ca/CertBasedEncryptionEnroll.html @@ -105,13 +105,6 @@ function setCRMFRequest() </SCRIPT> </head> -<OBJECT - classid="clsid:127698e4-e730-4e5c-a2b1-21490a70c8a1" - CODEBASE="/ee/xenroll.dll" - id=Enroll > -</OBJECT> - - <SCRIPT LANGUAGE=VBS> <!-- Function escapeDNComponent(comp) diff --git a/base/ca/shared/webapps/ca/ee/ca/CertBasedSingleEnroll.html b/base/ca/shared/webapps/ca/ee/ca/CertBasedSingleEnroll.html index fe6910efe..537d0870f 100644 --- a/base/ca/shared/webapps/ca/ee/ca/CertBasedSingleEnroll.html +++ b/base/ca/shared/webapps/ca/ee/ca/CertBasedSingleEnroll.html @@ -105,13 +105,6 @@ function setCRMFRequest() </SCRIPT> </head> -<OBJECT - classid="clsid:127698e4-e730-4e5c-a2b1-21490a70c8a1" - CODEBASE="/ee/xenroll.dll" - id=Enroll > -</OBJECT> - - <SCRIPT LANGUAGE=VBS> <!-- Function escapeDNComponent(comp) diff --git a/base/ca/shared/webapps/ca/ee/ca/DirPinUserEnroll.html b/base/ca/shared/webapps/ca/ee/ca/DirPinUserEnroll.html index 1c4ca22c2..b13b0136b 100644 --- a/base/ca/shared/webapps/ca/ee/ca/DirPinUserEnroll.html +++ b/base/ca/shared/webapps/ca/ee/ca/DirPinUserEnroll.html @@ -112,13 +112,6 @@ function setCRMFRequest() </SCRIPT> </head> -<OBJECT - classid="clsid:127698e4-e730-4e5c-a2b1-21490a70c8a1" - CODEBASE="/xenroll.dll" - id=Enroll > -</OBJECT> - - <SCRIPT LANGUAGE=VBS> <!-- Function escapeDNComponent(comp) diff --git a/base/ca/shared/webapps/ca/ee/ca/DirUserEnroll.html b/base/ca/shared/webapps/ca/ee/ca/DirUserEnroll.html index 703225a82..28b1b3d15 100644 --- a/base/ca/shared/webapps/ca/ee/ca/DirUserEnroll.html +++ b/base/ca/shared/webapps/ca/ee/ca/DirUserEnroll.html @@ -114,13 +114,6 @@ function setCRMFRequest() </SCRIPT> </head> -<OBJECT - classid="clsid:127698e4-e730-4e5c-a2b1-21490a70c8a1" - CODEBASE="/xenroll.dll" - id=Enroll > -</OBJECT> - - <SCRIPT LANGUAGE=VBS> <!-- Function escapeDNComponent(comp) diff --git a/base/ca/shared/webapps/ca/ee/ca/EnrollSuccess.template b/base/ca/shared/webapps/ca/ee/ca/EnrollSuccess.template index 771c6fb1b..d61c747cf 100644 --- a/base/ca/shared/webapps/ca/ee/ca/EnrollSuccess.template +++ b/base/ca/shared/webapps/ca/ee/ca/EnrollSuccess.template @@ -172,13 +172,6 @@ if (navigator.appName == 'Netscape' && (navMajorVersion() > 3) && //--> </SCRIPT> - -<OBJECT - classid="clsid:127698e4-e730-4e5c-a2b1-21490a70c8a1" - CODEBASE="/xenroll.dll" - id=Enroll > -</OBJECT> - <SCRIPT LANGUAGE=VBS> <!-- '======================================================== diff --git a/base/ca/shared/webapps/ca/ee/ca/ImportAdminCert.template b/base/ca/shared/webapps/ca/ee/ca/ImportAdminCert.template index e52764ec6..5d1015424 100644 --- a/base/ca/shared/webapps/ca/ee/ca/ImportAdminCert.template +++ b/base/ca/shared/webapps/ca/ee/ca/ImportAdminCert.template @@ -21,10 +21,6 @@ <TITLE>VBScript Administrator Certificate Enrollment </TITLE> <CMS_TEMPLATE> -<OBJECT classid="clsid:127698E4-E730-4E5C-A2b1-21490A70C8A1" - codebase="xenroll.dll" - id=Enroll > -</OBJECT> <SCRIPT language="VBScript"> <!-- Dim pkcs7 diff --git a/base/ca/shared/webapps/ca/ee/ca/ImportCert.template b/base/ca/shared/webapps/ca/ee/ca/ImportCert.template index 5530cf2d1..67ddd0c72 100644 --- a/base/ca/shared/webapps/ca/ee/ca/ImportCert.template +++ b/base/ca/shared/webapps/ca/ee/ca/ImportCert.template @@ -135,12 +135,6 @@ if (navigator.appName == 'Netscape' && (navMajorVersion() > 3) && </SCRIPT> <!-- -<OBJECT - classid="clsid:127698e4-e730-4e5c-a2b1-21490a70c8a1" - CODEBASE="/xenroll.dll" - id=Enroll > -</OBJECT> - <OBJECT id='g_objClassFactory' CLASSID='clsid:884e2049-217d-11da-b2a4-000e7bbb2b09'> </OBJECT> --> @@ -148,11 +142,7 @@ if (navigator.appName == 'Netscape' && (navMajorVersion() > 3) && <SCRIPT LANGUAGE="JavaScript"> //<!-- if (navigator.appName == "Microsoft Internet Explorer") { - if ((navigator.appVersion).indexOf("NT 6.") > -1) { - document.writeln("<OBJECT id='g_objClassFactory' CLASSID='clsid:884e2049-217d-11da-b2a4-000e7bbb2b09'></OBJECT>"); - } else { - document.writeln("<OBJECT classid='clsid:127698e4-e730-4e5c-a2b1-21490a70c8a1' CODEBASE='/xenroll.dll' id='Enroll'></OBJECT>"); - } + document.writeln("<OBJECT id='g_objClassFactory' CLASSID='clsid:884e2049-217d-11da-b2a4-000e7bbb2b09'></OBJECT>"); } //--> </SCRIPT> @@ -168,38 +158,12 @@ if (navigator.appName == "Microsoft Internet Explorer") { ' '======================================================== - 'Get OS Version, works for Vista and below only - Function GetOSVersion - dim agent - dim res - dim pos - - agent = Navigator.appVersion - pos = InStr(agent,"NT 6.") - - If pos > 0 Then - GetOSVersion = 6 - Exit Function - End If - - pos = InStr(agent,"NT 5.") - - If pos > 0 Then - GetOSVersion = 5 - Exit Function - End If - - GetOSVersion = 5 - End Function - 'Sub ImportCertificate Sub ImportCertificate (pkcs7) 'Dim pkcs7 Dim res - Dim osVersion On Error Resume Next - osVersion = GetOSVersion() 'Convert the cert to PKCS7 format 'pkcs7 = result.header.pkcs7ChainBase64 @@ -209,42 +173,22 @@ if (navigator.appName == "Microsoft Internet Explorer") { Exit Sub End If - If osVersion <> 6 Then 'Not Vista - - 'Import the PKCS7 object - Enroll.DeleteRequestCert = FALSE - Enroll.WriteCertToCSP = true - Enroll.acceptPKCS7(pkcs7) - if err.number <> 0 then - Enroll.WriteCertToCSP = false - end if - err.clear - Enroll.acceptPKCS7(pkcs7) - if err.number = 0 then - MsgBox "Certificate has been successfully imported." - else - sz = "Error in acceptPKCS7. Error Number " & Hex(err.number) & "occurred." - MsgBox sz - end if - Exit Sub - Else 'Vista - Dim enrollObj - - Set enrollObj = g_objClassFactory.CreateObject("X509Enrollment.CX509Enrollment") - If IsObject(enrollObj) = False Then - res = MsgBox("Can't create Enroll Object!") - Exit Sub - End If - - enrollObj.Initialize(1) - enrollObj.InstallResponse 0,pkcs7,6,"" - - If Err.number <> 0 Then - sz = "Error in InstallResponse. Error Number " & Hex(err.number) & " occurred." - res =MsgBox(sz & Err.description) - else - res = MsgBox("Certificate has been successfully imported.") - End If + Dim enrollObj + + Set enrollObj = g_objClassFactory.CreateObject("X509Enrollment.CX509Enrollment") + If IsObject(enrollObj) = False Then + res = MsgBox("Can't create Enroll Object!") + Exit Sub + End If + + enrollObj.Initialize(1) + enrollObj.InstallResponse 0,pkcs7,6,"" + + If Err.number <> 0 Then + sz = "Error in InstallResponse. Error Number " & Hex(err.number) & " occurred." + res =MsgBox(sz & Err.description) + else + res = MsgBox("Certificate has been successfully imported.") End If End Sub diff --git a/base/ca/shared/webapps/ca/ee/ca/ManObjSignEnroll.html b/base/ca/shared/webapps/ca/ee/ca/ManObjSignEnroll.html index 9c2c86a03..886a28929 100644 --- a/base/ca/shared/webapps/ca/ee/ca/ManObjSignEnroll.html +++ b/base/ca/shared/webapps/ca/ee/ca/ManObjSignEnroll.html @@ -135,13 +135,6 @@ function setCRMFRequest() </SCRIPT> </head> -<OBJECT - classid="clsid:127698e4-e730-4e5c-a2b1-21490a70c8a1" - CODEBASE="/xenroll.dll" - id=Enroll > -</OBJECT> - - <SCRIPT LANGUAGE=VBS> <!-- Function escapeDNComponent(comp) diff --git a/base/ca/shared/webapps/ca/ee/ca/ManUserEnroll.html b/base/ca/shared/webapps/ca/ee/ca/ManUserEnroll.html index e552f8e4a..85ba59c97 100644 --- a/base/ca/shared/webapps/ca/ee/ca/ManUserEnroll.html +++ b/base/ca/shared/webapps/ca/ee/ca/ManUserEnroll.html @@ -126,13 +126,6 @@ function setCRMFRequest() </SCRIPT> </head> -<OBJECT - classid="clsid:127698e4-e730-4e5c-a2b1-21490a70c8a1" - CODEBASE="/xenroll.dll" - id=Enroll > -</OBJECT> - - <SCRIPT LANGUAGE=VBS> <!-- Function escapeDNComponent(comp) diff --git a/base/ca/shared/webapps/ca/ee/ca/PortalEnrollment.html b/base/ca/shared/webapps/ca/ee/ca/PortalEnrollment.html index 8f3a373b4..b7e900939 100644 --- a/base/ca/shared/webapps/ca/ee/ca/PortalEnrollment.html +++ b/base/ca/shared/webapps/ca/ee/ca/PortalEnrollment.html @@ -132,13 +132,6 @@ function setCRMFRequest() </SCRIPT> </head> -<OBJECT - classid="clsid:127698e4-e730-4e5c-a2b1-21490a70c8a1" - CODEBASE="/xenroll.dll" - id=Enroll > -</OBJECT> - - <SCRIPT LANGUAGE=VBS> <!-- Function escapeDNComponent(comp) diff --git a/base/ca/shared/webapps/ca/ee/ca/ProfileSelect.template b/base/ca/shared/webapps/ca/ee/ca/ProfileSelect.template index a683867de..0b7a5418e 100644 --- a/base/ca/shared/webapps/ca/ee/ca/ProfileSelect.template +++ b/base/ca/shared/webapps/ca/ee/ca/ProfileSelect.template @@ -250,8 +250,7 @@ function keyTypeOptions (keyPurpose) if (keyFound == 0) { keyType = "RSA"; } - if ((isIE()) && - ((navigator.appVersion).indexOf("NT 6.") == -1)) { + if (isIE()) { keyType = "RSA"; } @@ -312,8 +311,7 @@ function keyLengthsCurvesOptions (keyPurpose) } } } - if ((isIE()) && - ((navigator.appVersion).indexOf("NT 6.") == -1)) { + if (isIE()) { keyType = "RSA"; } @@ -524,11 +522,7 @@ function setCRMFRequest() } } if (isIE()) { - if ((navigator.appVersion).indexOf("NT 6.") > -1) { - document.writeln("<OBJECT id='g_objClassFactory' CLASSID='clsid:884e2049-217d-11da-b2a4-000e7bbb2b09'></OBJECT>"); - } else { - document.writeln("<OBJECT classid='clsid:127698e4-e730-4e5c-a2b1-21490a70c8a1' CODEBASE='/xenroll.dll' id='Enroll'></OBJECT>"); - } + document.writeln("<OBJECT id='g_objClassFactory' CLASSID='clsid:884e2049-217d-11da-b2a4-000e7bbb2b09'></OBJECT>"); document.writeln('<form name="ReqForm" onSubmit="if (checkRequest()) {return true;} else {window.location.reload(); return false;}" method="post" action="' + uri + '">'); } else if (typeof(crypto) != "undefined" && typeof(crypto.version) != "undefined") { document.writeln('<form name="ReqForm" onSubmit="return validate();" method="post" action="' + uri + '">'); @@ -539,36 +533,10 @@ function setCRMFRequest() <SCRIPT LANGUAGE=VBS> <!-- -'Get OS Version, works for Vista and below only -Function GetOSVersion - dim agent - dim result - dim pos - - agent = Navigator.appVersion - pos = InStr(agent,"NT 6.") - - If pos > 0 Then - GetOSVersion = 6 ' Vista - Exit Function - End If - - pos = InStr(agent,"NT 5.") - - If pos > 0 Then - GetOSVersion = 5 ' XP etc - Exit Function - End If - -' Default - GetOSVersion = 5 -End Function - Function checkRequest Dim TheForm Dim szName Dim options - Dim osVersion Dim result Dim keyLen Dim keyParameter @@ -586,141 +554,89 @@ Function checkRequest keyParameter = TheForm.all.keyLength.options(keyIndex).value End If - osVersion = GetOSVersion() + Dim enrollment + Dim privateKey + Dim request + Dim csr + Dim objDN - If osVersion <> 6 Then 'Not Vista - - ' Contruct the X500 distinguished name - szName = "CN=NAME" + 'certUsage is "1.3.6.1.5.5.7.3.2" On Error Resume Next - Enroll.HashAlgorithm = "MD5" - Enroll.KeySpec = 1 - - ' Pick the provider that is selected - set options = TheForm.all.cryptprovider.options - index = options.selectedIndex - Enroll.providerType = options(index).value - Enroll.providerName = options(index).text - - ' adding 2 to "GenKeyFlags" will enable the 'High Security' - ' (USER_PROTECTED) mode, which means IE will pop up a dialog - ' asking what level of protection you would like to give - ' the key - this varies from 'none' to 'confirm password - ' every time the key is used' - ' Enroll.GenKeyFlags = 1 ' key PKCS12-exportable - Enroll.GenKeyFlags = (65536 * (CLng(keyLen))) + 1 - szCertReq = Enroll.createPKCS10(szName, "1.3.6.1.5.5.7.3.2") - theError = Err.Number - On Error Goto 0 - ' - ' If the user has cancelled things the we simply ignore whatever - ' they were doing ... need to think what should be done here - ' - If (szCertReq = Empty AND theError = 0) Then - Exit Function - End If + 'CreateObject("X509Enrollment.CX509EnrollmentWebClassFactory") - If (szCertReq = Empty OR theError <> 0) Then - ' - ' There was an error in the key pair generation. The error value - ' is found in the variable 'theError' which we snarfed above before - ' we did the 'On Error Goto 0' which cleared it again. - ' - sz = "The error '" & Hex(theError) & "' occurred." & chr(13) & chr(10) & "Your credentials could not be generated." - result = MsgBox(sz, 0, "Credentials Enrollment") + If IsObject(g_objClassFactory) = False Then + result = MsgBox("Can't create Factory Object " & " Error: " & Err.number & " :" & Err.description,0,"") Exit Function End If - TheForm.cert_request.Value = szCertReq - - ' TheForm.Submit - - Else 'Vista - Dim enrollment - Dim privateKey - Dim request - Dim csr - Dim objDN + Set enrollment = g_objClassFactory.CreateObject("X509Enrollment.CX509Enrollment") - 'certUsage is "1.3.6.1.5.5.7.3.2" - - On Error Resume Next - 'CreateObject("X509Enrollment.CX509EnrollmentWebClassFactory") - - If IsObject(g_objClassFactory) = False Then - result = MsgBox("Can't create Factory Object " & " Error: " & Err.number & " :" & Err.description,0,"") - Exit Function - End If - - Set enrollment = g_objClassFactory.CreateObject("X509Enrollment.CX509Enrollment") - - If IsObject(enrollment) = False Then - result = MsgBox("Can't create enroll Object! " & " Error: " & Err.number & " :" & Err.description,"") - Exit Function - End If + If IsObject(enrollment) = False Then + result = MsgBox("Can't create enroll Object! " & " Error: " & Err.number & " :" & Err.description,"") + Exit Function + End If - Set privateKey = g_objClassFactory.CreateObject("X509Enrollment.CX509PrivateKey") + Set privateKey = g_objClassFactory.CreateObject("X509Enrollment.CX509PrivateKey") - If IsObject(privateKey) = False Then - result = MsgBox("Can't create Key Object! " & " Error: " & Err.number & " :" & Err.description,0,"") - Exit Function - End If + If IsObject(privateKey) = False Then + result = MsgBox("Can't create Key Object! " & " Error: " & Err.number & " :" & Err.description,0,"") + Exit Function + End If - Set request = g_objClassFactory.CreateObject("X509Enrollment.CX509CertificateRequestPkcs10") + Set request = g_objClassFactory.CreateObject("X509Enrollment.CX509CertificateRequestPkcs10") - If IsObject(request) = False Then - result = MsgBox("Can't create Request Object. ! " & " Error: " & Err.number & " :" & Err.description,0,"") - Exit Function - End If + If IsObject(request) = False Then + result = MsgBox("Can't create Request Object. ! " & " Error: " & Err.number & " :" & Err.description,0,"") + Exit Function + End If - Set algobj = g_objClassFactory.CreateObject( "X509Enrollment.CObjectId" ) - If IsObject(algobj) = False Then - result = MsgBox("Can't create OID Object. ! " & " Error: " & Err.number & " :" & Err.description,0,"") - Exit Function - End If - algobj.InitializeFromAlgorithmName XCN_CRYPT_ANY_GROUP_ID, XCN_CRYPT_OID_INFO_PUBKEY_ANY, AlgorithmFlagsNone, keyParameter - privateKey.Algorithm = algobj + Set algobj = g_objClassFactory.CreateObject( "X509Enrollment.CObjectId" ) + If IsObject(algobj) = False Then + result = MsgBox("Can't create OID Object. ! " & " Error: " & Err.number & " :" & Err.description,0,"") + Exit Function + End If + algobj.InitializeFromAlgorithmName XCN_CRYPT_ANY_GROUP_ID, XCN_CRYPT_OID_INFO_PUBKEY_ANY, AlgorithmFlagsNone, keyParameter + privateKey.Algorithm = algobj - privateKey.KeySpec= "1" + privateKey.KeySpec= "1" ' Allows key to be exported. - privateKey.ExportPolicy = "1" + privateKey.ExportPolicy = "1" ' Pick the provider that is selected - set options = TheForm.all.cryptprovider.options - index = options.selectedIndex - privateKey.ProviderType = index - privateKey.ProviderName = options(index).text - If keyLen > 0 Then - privateKey.Length = keyLen - End If + set options = TheForm.all.cryptprovider.options + index = options.selectedIndex + privateKey.ProviderType = index + privateKey.ProviderName = options(index).text + If keyLen > 0 Then + privateKey.Length = keyLen + End If - szName = "0.9.2342.19200300.100.1.1=" & TheForm.uid.Value & ",E=" & TheForm.email.Value & ",CN=" & TheForm.cn.Value + szName = "0.9.2342.19200300.100.1.1=" & TheForm.uid.Value & ",E=" & TheForm.email.Value & ",CN=" & TheForm.cn.Value - Set objDN = g_objClassFactory.CreateObject("X509Enrollment.CX500DistinguishedName") + Set objDN = g_objClassFactory.CreateObject("X509Enrollment.CX500DistinguishedName") - If IsObject(objDN) = False Then - result = MsgBox("Can't create DN Object. ! " & " Error: " & Err.number & " :" & Err.description,0,"") - Exit Function - End If + If IsObject(objDN) = False Then + result = MsgBox("Can't create DN Object. ! " & " Error: " & Err.number & " :" & Err.description,0,"") + Exit Function + End If - objDN.Encode szName,0 + objDN.Encode szName,0 - request.InitializeFromPrivateKey 1,privateKey,"" - request.Subject = objDN + request.InitializeFromPrivateKey 1,privateKey,"" + request.Subject = objDN - enrollment.InitializeFromRequest(request) - csr=enrollment.CreateRequest(1) + enrollment.InitializeFromRequest(request) + csr=enrollment.CreateRequest(1) - If len(csr) = 0 Then - result = MsgBox("Error Creating Request! "& " Error: " & Err.number & " :" & Err.description,0,"") - Exit Function - End If + If len(csr) = 0 Then + result = MsgBox("Error Creating Request! "& " Error: " & Err.number & " :" & Err.description,0,"") + Exit Function + End If - TheForm.cert_request.Value = csr + TheForm.cert_request.Value = csr - End If checkRequest = True End Function @@ -988,105 +904,61 @@ Function FindProviders On Error Resume Next first = 0 - Dim osVersion Dim result - osVersion = GetOSVersion() - - If osVersion <> 6 Then 'Not Vista - Do While True - temp = "" - Enroll.providerType = j - temp = Enroll.enumProviders(i,0) - If Len(temp) = 0 Then - If j < 1 Then - j = j + 1 - i = 0 - Else - Exit Do - End If - Else - set el = document.createElement("OPTION") - el.text = temp - el.value = j - If temp = "Microsoft Base Cryptographic Provider v1.0" Then - first = i - End If - If temp = "Microsoft Strong Cryptographic Provider" Then - firstS = i - End If - If temp = "Microsoft Enhanced Cryptographic Provider v1.0" Then - firstE = i - End If - TheForm.cryptprovider.add(el) - If firstE > 0 Then - TheForm.cryptprovider.selectedIndex = firstE - ElseIf firstS > 0 Then - TheForm.cryptprovider.selectedIndex = firstS - ElseIf first > 0 Then - TheForm.cryptprovider.selectedIndex = first - Else - first = 1 - TheForm.cryptprovider.selectedIndex = 0 - End If - i = i + 1 - End If - Loop - Else 'Vista - Dim csps - Set csps = g_objClassFactory.CreateObject("X509Enrollment.CCspInformations") - If IsObject(csps) = False Then - result = MsgBox("Can't create CSP List Object! " & " Error: " & Err.number & " :" & Err.description,0,"") - Exit Function - - End If - csps.AddAvailableCsps() - 'result = MsgBox(csps.Count,0,"Number of CSPS") - - Dim curName - Dim csp - Dim selected - Dim selectedS - Dim selectedE - Dim selectedEC - selected = -1 - selectedS = -1 - selectedE = -1 - selectedEC = -1 - For i = 0 to csps.Count-1 - - curName = csps.ItemByIndex(i).Name - If len(curName) > 0 Then - Set csp = document.createElement("OPTION") - csp.text = curName - csp.value = 1 - TheForm.cryptprovider.add(csp) - - If curName = "Microsoft Base Cryptographic Provider v1.0" Then - selected = i - End If - If curName = "Microsoft Strong Cryptographic Provider" Then - selectedS = i - End If - If curName = "Microsoft Enhanced Cryptographic Provider v1.0" Then - selectedE = i - End If - If curName = "Microsoft Software Key Storage Provider" Then - selectedEC = i - End If - 'result = MsgBox(curName,0,"") - End If - Next - If selectedEC >= 0 Then - TheForm.cryptprovider.selectedIndex = selectedEC - ElseIf selectedE >= 0 Then - TheForm.cryptprovider.selectedIndex = selectedE - ElseIf selectedS >= 0 Then - TheForm.cryptprovider.selectedIndex = selectedS - ElseIf selected >= 0 Then - TheForm.cryptprovider.selectedIndex = selected - Else - TheForm.cryptprovider.selectedIndex = 0 - End If + Dim csps + Set csps = g_objClassFactory.CreateObject("X509Enrollment.CCspInformations") + If IsObject(csps) = False Then + result = MsgBox("Can't create CSP List Object! " & " Error: " & Err.number & " :" & Err.description,0,"") + Exit Function + + End If + csps.AddAvailableCsps() + 'result = MsgBox(csps.Count,0,"Number of CSPS") + + Dim curName + Dim csp + Dim selected + Dim selectedS + Dim selectedE + Dim selectedEC + selected = -1 + selectedS = -1 + selectedE = -1 + selectedEC = -1 + For i = 0 to csps.Count-1 + + curName = csps.ItemByIndex(i).Name + If len(curName) > 0 Then + Set csp = document.createElement("OPTION") + csp.text = curName + csp.value = 1 + TheForm.cryptprovider.add(csp) + + If curName = "Microsoft Base Cryptographic Provider v1.0" Then + selected = i + End If + If curName = "Microsoft Strong Cryptographic Provider" Then + selectedS = i + End If + If curName = "Microsoft Enhanced Cryptographic Provider v1.0" Then + selectedE = i + End If + If curName = "Microsoft Software Key Storage Provider" Then + selectedEC = i + End If + 'result = MsgBox(curName,0,"") + End If + Next + If selectedEC >= 0 Then + TheForm.cryptprovider.selectedIndex = selectedEC + ElseIf selectedE >= 0 Then + TheForm.cryptprovider.selectedIndex = selectedE + ElseIf selectedS >= 0 Then + TheForm.cryptprovider.selectedIndex = selectedS + ElseIf selected >= 0 Then + TheForm.cryptprovider.selectedIndex = selected + Else + TheForm.cryptprovider.selectedIndex = 0 End If End Function diff --git a/base/ca/shared/webapps/ca/ee/ca/RenewalSuccess.template b/base/ca/shared/webapps/ca/ee/ca/RenewalSuccess.template index cb840d296..73465691b 100644 --- a/base/ca/shared/webapps/ca/ee/ca/RenewalSuccess.template +++ b/base/ca/shared/webapps/ca/ee/ca/RenewalSuccess.template @@ -158,12 +158,6 @@ if (navigator.appName == 'Netscape' && (navMajorVersion() > 3) && //--> </SCRIPT> -<OBJECT - classid="clsid:127698e4-e730-4e5c-a2b1-21490a70c8a1" - CODEBASE="/xenroll.dll" - id=Enroll > -</OBJECT> - <SCRIPT LANGUAGE=VBS> <!-- '======================================================== diff --git a/base/ca/shared/webapps/ca/ee/ca/displayBySerial.template b/base/ca/shared/webapps/ca/ee/ca/displayBySerial.template index 33bc45f22..be65418be 100644 --- a/base/ca/shared/webapps/ca/ee/ca/displayBySerial.template +++ b/base/ca/shared/webapps/ca/ee/ca/displayBySerial.template @@ -134,12 +134,6 @@ To import the certificate into your client, click the following button. </font> <p> -<OBJECT - classid="clsid:127698e4-e730-4e5c-a2b1-21490a70c8a1" - CODEBASE="/xenroll.dll" - id=Enroll > -</OBJECT> - <SCRIPT LANGUAGE=VBS> <!-- '======================================================== |