From edewata at redhat.com Wed Aug 1 04:39:21 2012 From: edewata at redhat.com (Endi Sukma Dewata) Date: Tue, 31 Jul 2012 23:39:21 -0500 Subject: [Pki-devel] [PATCH] 85 Added SSL authenticator with fallback. In-Reply-To: <5017DB1D.7020600@redhat.com> References: <50119E06.8040603@redhat.com> <5017DB1D.7020600@redhat.com> Message-ID: <5018B2F9.90105@redhat.com> On 7/31/2012 8:18 AM, Endi Sukma Dewata wrote: > New patch attached. This patch contains the authenticator only. The SSL > configuration will be modified in a later patch. ACKed by Ade. Pushed to master. -- Endi S. Dewata From edewata at redhat.com Wed Aug 1 04:39:32 2012 From: edewata at redhat.com (Endi Sukma Dewata) Date: Tue, 31 Jul 2012 23:39:32 -0500 Subject: [Pki-devel] [PATCH] 87 Refactored PKI JNDI realm. In-Reply-To: <5017DB27.2010403@redhat.com> References: <5017DB27.2010403@redhat.com> Message-ID: <5018B304.2040707@redhat.com> On 7/31/2012 8:18 AM, Endi Sukma Dewata wrote: > The PKI JNDI realm has been modified to utilize the authentication > and authorization subsystems in PKI engine directly. It's no longer > necessary to define the LDAP connection settings in Tomcat's > configuration files. ACKed by Ade. Pushed to master. -- Endi S. Dewata From edewata at redhat.com Wed Aug 1 04:39:55 2012 From: edewata at redhat.com (Endi Sukma Dewata) Date: Tue, 31 Jul 2012 23:39:55 -0500 Subject: [Pki-devel] [PATCH] 88 Merged pki-jndi-realm.jar into pki-cmscore.jar. In-Reply-To: <5017DB2C.8000709@redhat.com> References: <5017DB2C.8000709@redhat.com> Message-ID: <5018B31B.4020902@redhat.com> On 7/31/2012 8:18 AM, Endi Sukma Dewata wrote: > On Tomcat 7 it's no longer necessary to have a separate package > for the authenticator and realm classes. They are now packaged > in pki-cmscore.jar which is deployed in Tomcat's common/lib. ACKed by Ade. Pushed to master. -- Endi S. Dewata From edewata at redhat.com Wed Aug 1 22:44:18 2012 From: edewata at redhat.com (Endi Sukma Dewata) Date: Wed, 01 Aug 2012 17:44:18 -0500 Subject: [Pki-devel] [PATCH] 27 Dogtag 10 Beta - Ticket 150 . Implement Cert search/list request in CLI In-Reply-To: <1343749603.9474.1.camel@akoneru.redhat.com> References: <1343749603.9474.1.camel@akoneru.redhat.com> Message-ID: <5019B142.1020209@redhat.com> On 7/31/2012 10:46 AM, Abhishek Koneru wrote: > Please review the attached patch, which has the fix for Ticket 150. Implementing interface for all the UI search - request functionality in CLI. > Also attached the sample cert request xml form file. > > --Abhishek Koneru The patch needs rebasing and there's a conflict. As discussed, go ahead and override my recent changes to cert-find because it doesn't seem to be needed anymore. Some comments: 1. The CertFindCLI.printHelp() generates the following help message: usage: cert-find(Optional) [OPTIONS...] I think we can use the [...] to indicate the optional filename, so it will look like this (also note the spacing): usage: cert-find [filename] [OPTIONS...] 2. Optional: We don't have this yet, but we might want to reserve the command line argument for search keyword which can be used to search all fields: pki cert-find abhishek It would match 'abhishek' in username, email, subject DN, etc. If we decide to do this, we would use an option to specify the file name: usage: cert-find [keyword] [OPTIONS...] --input File containing the search constraints. 3. The code in CertFindCLI.java:68 needs formatting. 4. The if-then condition in line 75 can be simplified as follows: if () { // load searchData from file } else { // create default searchData } // modify searchData based on the options The code in line 99-101 is no longer needed. 5. In line 104 it's not necessary to use a loop to iterate through all options. // modify searchData based on the options applyOptions(cmd, searchData) In applyOptions() it can go through all possible options sequentially: if (!cmd.hasOption("minSerialNumber")) { searchData.setSerialNumberRangeInUse(true); searchData.setSerialFrom(cmd.getOptionValue("minSerialNumber")); } if (!cmd.hasOption("maxSerialNumber")) { searchData.setSerialNumberRangeInUse(true); searchData.setSerialTo(cmd.getOptionValue("maxSerialNumber")); } It's not necessary to trim() the value because they are are already trimmed unless they are quoted. 6. In line 111 it should show the exception message. 7. In line 114 it should check the certInfos size too: if (certs.getCertInfos() == null || certs.getCertInfos().isEmpty()) { // no matches found } 8. In addOptions() the option descriptions are not consistent. Let's capitalize the first word only, e.g. "Minimum serial number", and use no space before colon, one space after that. 9. If an option has an argument (the third param is true) we should specify the argument name, for example: option = new Option(null, "validNotBeforeFrom", true, "Valid not before start date"); option.setArgName("date") options.addOption(option); It will appear as: --validNotBeforeFrom Valid not before start date 10. The option description should include the default value (if any) and acceptable values (if not obvious from the description) or example, for example the date format. This might require investigating the server code. Feel free to file a ticket for this. 11. The CertSearchData.valueOf() should take a more generic input, e.g. Reader, so it can be used to read other inputs, not just files. -- Endi S. Dewata From awnuk at redhat.com Thu Aug 2 01:02:50 2012 From: awnuk at redhat.com (Andrew Wnuk) Date: Wed, 01 Aug 2012 18:02:50 -0700 Subject: [Pki-devel] ECC enrollments for IE Message-ID: <5019D1BA.5090203@redhat.com> This patch enables ECC enrollments for IE. Bug: 748514. -------------- next part -------------- Index: pki/redhat/ca-ui/shared/webapps/ca/ee/ca/ProfileSelect.template =================================================================== --- pki/redhat/ca-ui/shared/webapps/ca/ee/ca/ProfileSelect.template (revision 16023) +++ pki/redhat/ca-ui/shared/webapps/ca/ee/ca/ProfileSelect.template (working copy) @@ -75,13 +75,39 @@ if (keyFound == 0) { keyType = "RSA"; } - if (navigator.appName == "Microsoft Internet Explorer") { + if ((navigator.appName == "Microsoft Internet Explorer") && + ((navigator.appVersion).indexOf("NT 6.") == -1)) { keyType = "RSA"; } return keyType; } +function translateCurveName (name) +{ + var translated = ""; + if (navigator.appName == "Microsoft Internet Explorer") { + if (name == "nistp256" || name == "ECDSA_P256") { + translated = "ECDSA_P256"; + } else if (name == "nistp384" || name == "ECDSA_P384") { + translated = "ECDSA_P384"; + } else if (name == "nistp521" || name == "ECDSA_P521") { + translated = "ECDSA_P521"; + } + } else { + if (name == "ECDSA_P256") { + translated = "nistp256"; + } else if (name == "ECDSA_P384") { + translated = "nistp384"; + } else if (name == "ECDSA_P521") { + translated = "nistp521"; + } else { + translated = name; + } + } + return translated; +} + function keyLengthsCurvesOptions (keyPurpose) { var keyType = "RSA"; @@ -111,23 +137,33 @@ } } } - if (navigator.appName == "Microsoft Internet Explorer") { + if ((navigator.appName == "Microsoft Internet Explorer") && + ((navigator.appVersion).indexOf("NT 6.") == -1)) { keyType = "RSA"; } var value = 0; - var included = true; var l = 0; for (l = 0 ; l < lengthsOrCurves.length; l++) { + var included = true; value = lengthsOrCurves[l]; if (keyType != "EC" && !isNumeric(value)) { included = false; + } else if (keyType == "EC" && + navigator.appName == "Microsoft Internet Explorer" && + value != "nistp256" && value != "nistp384" && value != "nistp521" & + value != "ECDSA_P256" && value != "ECDSA_P384" && value != "ECDSA_P521") { + included = false; } if (included) { - options += '