tag:blogger.com,1999:blog-79333483722649716212009-06-25T16:29:05.963+02:00EJBCA - Open Source Enterprise PKITech blog for EJBCA enterprise open source PKI. Useful (hopefully) tips for the world.tomashttp://www.blogger.com/profile/15030707839569169791noreply@blogger.comBlogger33125tag:blogger.com,1999:blog-7933348372264971621.post-76202486929953806012009-06-25T16:24:00.003+02:002009-06-25T16:29:05.974+02:00Accessing the WS signing certificate from inside a JAX-WS webserviceWhen I have set up the webservice as in the previous post to require signatures, it's very normal that I would like to know who signed the certificate. Also I probably want to access the credentials of the signature, in this case the certificate. <br /><br />How do I retrieve the signature certificate of a WS-security signed SOAP message?<br /><br />I could not find any good post describing this on the Internet...<br /><br />Well here it is now:<br /><br /><pre><br /> @Resource<br /> private WebServiceContext wsContext; <br /><br />&lt;snip><br /><br /> MessageContext mctx = wsContext.getMessageContext(); <br /> Subject s = (Subject)mctx.get("CLIENT_SUBJECT");<br /> Set cs = s.getPublicCredentials();<br /> for (Iterator iterator = cs.iterator(); iterator.hasNext();) {<br /> Object object = (Object) iterator.next();<br /> System.out.println("Object: "+object.getClass().getName());<br /> if (object instanceof X509Certificate) {<br /> System.out.println("Found a certificate");<br /> X509Certificate cert = (X509Certificate) object;<br /> System.out.println(cert.toString());<br /> }<br /> }<br /> if (s != null) {<br /> Set<Principal> ps = s.getPrincipals();<br /> for (Iterator iterator = ps.iterator(); iterator.hasNext();) {<br /> Principal principal = (Principal) iterator.next();<br /> if (principal instanceof X500Principal) {<br /> X500Principal xp = (X500Principal) principal;<br /> System.out.println(xp.getName());<br /> }<br /> }<br /> }<br /><br />&lt;snip><br /><br /></pre><div class="blogger-post-footer"><img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/7933348372264971621-7620248692995380601?l=blog.ejbca.org'/></div>tomashttp://www.blogger.com/profile/15030707839569169791noreply@blogger.com0tag:blogger.com,1999:blog-7933348372264971621.post-29359668023571360342009-06-22T19:23:00.003+02:002009-06-22T19:26:14.748+02:00Configuring Glassfish and SOAPui to use message level security with digital signaturesI made a simple Jax-WS project with simple webservice. The tricky part is that I wanted message level security with WS-security digital signatures authenticating the message. It took me a while to get it right, so here is how it's done. You can configure WS-security layer on the server side simply by configuring Glassfish use it for all soap messaging. This was the easiest way for me to set it up.<br /><br />* Configure glassfish:<br /><br />This will use the default server keystore for signatures, the same keystore that is used for SSL.<br /><br />In admin console go to: Configuration->Security->Message Security->SOAP<br />In Message Security tab select:<br /><br />Default Provider: ServerProvider<br />Default Client Provider: ClientProvider<br /><br />In Providers tab click ServerProvider:<br /><br />Provider Type: server<br />class name (default): com.sun.xml.wss.provider.ServerSecurityAuthModule<br />Request policy:<br />- Authenticate Source: content<br />- Authenticate Recipient: null (blank) <br /><br />Response policy:<br />- Authenticate Source: content<br />- Authenticate Recipient: null (blank) <br /><br />Additional Properties:<br />leave as default<br /><br />* Configure SOAPui<br /><br />Create a project and send a message to the server. When the server is configured to require signature you should receive a "Error validating request" message back.<br /><br />Open project view. Go to tab Security Configuration->Keystores/Certificates.<br />Add a keystore glassfish/domains/domain1/config/keystore.jks, password changeit and default alias s1as.<br />Change to tab Outgoing WS-Security Configurations. Create a new configuration called "sign".<br />Add a new WSS Entry called Timestamp with Time To Live 1000 (or something). <br />Add a new WSS Entry called Signature:<br />- Keystore: keystore.jks<br />- Alias: s1as<br />- Password: changeit<br />- Key Identifier Type: Binary Security Token<br />- Signature Algorithm: http://www.w3.org/2000/09/xmldsig#rsa-sha1<br />- Signature Canonicalization: http://www.w3.org/2001/10/xml-exc-c14n#<br />- Use single certificate for signing<br />- Add a new part: Name=Body, Namespace=http://schemas.xmlsoap.org/soap/envelope/, Encode=Element<br />- Add a new part: Name=Timestamp, Namespace=http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd, Encode=Element<br /><br />Finally in the request window add the configuration. Select XML view and click Aut in the bottom, select Outgoing WSS=Sign<br /><br />Now you will probably have an issue with glassfish being unable to verify your message. This is due to canonicalization and SOAPui making nice display of the XML for you.<br />Go into the XML view and remove all whitespace and newlines in the soapenv:Body tag.<br /><br />Now it should work!<div class="blogger-post-footer"><img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/7933348372264971621-2935966802357136034?l=blog.ejbca.org'/></div>tomashttp://www.blogger.com/profile/15030707839569169791noreply@blogger.com0tag:blogger.com,1999:blog-7933348372264971621.post-58829944259283607102009-06-07T15:27:00.003+02:002009-06-07T15:38:10.680+02:00Build an open source enterprise OCSP validation serviceBuild a high performance OCSP responder using EJBCA. EJBCA is a J2EE enterprise open source PKI that you can deploy as a certificate authority or an ocsp responder.<br /><br /><a href="http://www.ejbca.org">EJBCA</a> is a J2EE enterprise open source PKI that you can deploy as a certificate authority or an ocsp responder.<br /><br />With the release fo EJBCA 3.9.0 it is easier than ever to set up a high performance, high reliability OCSP responder.<br />OCSP stands for online certificate status protocol and is defined in RFC2560. In short it provides an online service for validating that a certicate, as used by SSL or VPN etc, has not been revoked. OCSP has the basic functionality defined in RFC2560 and this, in it's plain form, it widely used. If using a high speed hardware security module (HSM) for signature operations you can easily answer 500 requests per second with the EJBCA external OCSP responder. Certificate status information is kept in a regular database, such as MySQL, making it very suitable for online services because you can really update the information on line without waiting for the certificate authority to issued certificate revocation lists (CRLs).<br /><br />To further improve scalability of OCSP IETF has defined a lighweight OCSP profile in RFC5019. This profile builds on the usage of http get instead of http put which is the default transport used. Using http get the responder can set http headers to enable caching by regular proxies. Caching makes the service slightly less online, in the meaning that you always gets fresh information, but can improve performance across networks. EJBCA 3.9.0 improves the EJBCA external OCSP responder with full support for RFC5019.<br /><br />If you plan on building an OCSP service there are many things to consider:<br />- standards support<br />- performance<br />- scalability by adding cluster nodes<br />- transaction and audit logging<br />- authentication of callers, possibly requiring signed requests<br />- use of custom OCSP extensions<br />- OCSP responder independent of CA service provider<br />- renewal of OCSP responder keys<br /><br />A typical configuration for OCSP uses two or more OCSP responder nodes. Each OCSP responder keeps it's own database. By using it's own database you can assure truly high availability because the nodes are completely independent and you can do maintenance on one node, including the database, without affecting uptime of the service. The OCSP responder nodes should be connected to a set of HSMs in a high availability setup, if one HSM breaks, another keeps the service running albeit with less available performance.<br />Each OCSP responder will produce full transaction and audit logging. Audit logging is needed in order to maintain trust, since a validation service such as OCSP is about trust. Transaction logging will be needed if you want to keep records of users of the service either for billing purposes or to keep statistics.<br /><br />Visit <a href="http://www.ejbca.org">EJBCA.org</a> for downloads and documentation.<div class="blogger-post-footer"><img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/7933348372264971621-5882994425928360710?l=blog.ejbca.org'/></div>tomashttp://www.blogger.com/profile/15030707839569169791noreply@blogger.com0tag:blogger.com,1999:blog-7933348372264971621.post-67676521459963115422009-06-07T14:43:00.003+02:002009-06-07T14:51:13.946+02:00EJBCA 3.9.0 releasedAfter much hard work, EJBCA 3.9.0 is finally released. This might just<br />be the best release ever of EJBCA :-)<br /><br /><br />This is a major release adding many new features and improvements, and fixing numerous bugs.<br />126 issues have been resolved for this release. Check the changelog, there is a good chance that your favorite issue has been resolved.<br /><br />Some noteworthy changes:<br />- Support for CAs using DSA keys. EJBCA now supports all major algorithms; RSA, DSA and ECDSA.<br />- External RA improvements. CA service running as an EJBCA services gives full cluster functionality and support for multiple external RAs. As a bonus it is now much easier to install and configure.<br />- Robust re-publishing mechanism for publishers that fail, running as an<br />EJBCA service.<br />- OCSP responder improvements with performance improvements and support<br />for on-line renewal of OCSP responder keys and certificates. The external OCSP responder can now saturate high performance HSMs.<br />- OCSP monitoring tool for monitoring synchronization between EJBCA and<br />external OCSP responders.<br />- GUI for configuring the external OCSP publisher with new options.<br />- Possible to change OCSP signing keys in a running external OCSP responder.<br />- New commands and stress tests in the client toolbox.<br />- A new admin web gui front page with status overview panels.<br />- Possible to configure status of certificates issued for end entities, i.e. issue certificate revoked "on hold".<br />- New DN attribute, Name.<br />- Performance improvement by caching and lowering number of database queries.<br />- XKMS now works also on Java 6.<br />- Possibility to set user validity start and end time in WS API.<br />- Lots of small fixes and improvements to the admin GUI.<br />- Lots of small bugfixes.<br />- Keon CA to EJBCA migration guide.<br /><br />Note that the configuration of External RA changed dramatically (to the better). If using the external RA, please read the manual how to install and configure the RA CA service in EJBCA 3.9.<br /><br />Note that this version brings database changes. Read the UPGRADE document for upgrade instructions.<br /><br />This release should, as always, work on JBoss, Glassfish, Weblogic and OC4J, together with most available databases.<br /><br />Read the <a href="https://jira.primekey.se/browse/ECA?report=com.atlassian.jira.plugin.system.project%3Achangelog-panel">changelog</a> for details.<div class="blogger-post-footer"><img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/7933348372264971621-6767652145996311542?l=blog.ejbca.org'/></div>tomashttp://www.blogger.com/profile/15030707839569169791noreply@blogger.com0tag:blogger.com,1999:blog-7933348372264971621.post-39781319631252063472009-05-11T15:12:00.006+02:002009-05-11T15:26:47.580+02:00New status overview in the EJBCA admin GUIIn EJBCA 3.9 the admin GUI will get it's first really nice update in a year or so. Apart from the usual additional options etc that pops up in every release, this release changes a fundamental concept - the first page.<br />We have long been thinking about have the first page be a kind of portal page where an administrator can get an overview of important status and information of the system. Originally we was planning this for the major re-make of the admin gui planned for 4.1. In 3.9 we got the opportunity, thanks to corporate sponsored development and our new developer Markus.<br /><br />The first page meeting the administrator now has two panels- One with an overview of CAs on-line/off-line status and CRL status and one with number of pending publisher queue items (new feature in 3.9).<br /><br /><iframe class="forma" src="https://sourceforge.net/dbimage.php?id=215276" height="400" width="500"></iframe><br /><br />We even got some new style sheet items in there :-).<br />Combined with the on-line documentation links from the admin GUI (question marks in the image) it's really nice.<br /><br />View a full set of screen shots at <a href="https://sourceforge.net/project/screenshots.php?group_id=39716">sourceforge</a>.<div class="blogger-post-footer"><img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/7933348372264971621-3978131963125206347?l=blog.ejbca.org'/></div>tomashttp://www.blogger.com/profile/15030707839569169791noreply@blogger.com0tag:blogger.com,1999:blog-7933348372264971621.post-62574343916725736552009-04-26T13:14:00.004+02:002009-04-27T18:43:30.717+02:00Migrating ext3 to ext4 on an encrypted root disk (ubuntu 9.04)Ext4 is supposed to be much faster than ext3. Anything that makes development of EJBCA a bit quicker is interesting, so I just had to migrate to ext4 now that Ubuntu 9.04 is out.<br />The usual ext3 to ext4 migration guides are for normal unencrypted disk. Since my laptop has full disk enryption a few addition steps are needed.<br />Also the guides mention that you have to do 'grub-install' after migration. I did not have to do that. <br />Either it is because:<br />- I only migrated / and not /boot<br />- The standard upgrade to Ubuntu 9.04 already installed a new grub for me.<br /><br />Anyhow, here are the steps hwo to migrate an encrypted root disk from ext3 to ext4.<br /><br />Shut down computer properly, don't hibernate.<br />Boot from Ubuntu 9.04 cd and use it as a live cd (no changes to computer). <br />Open a terminal and become root.<br /><span style="font-style:italic;">#sudo su -</span><br /><br />Set up crypto add encrypted disk to lvm<br /><span style="font-style:italic;">#cryptsetup luksOpen /dev/sda1 root<br />#lvm vgchange -a y</span><br /><br />Mount root disk and just check that it's the correct disk before migrating<br /><span style="font-style:italic;">#mkdir /mnt/root<br />#mount /dev/tlap/root /mnt/root</span><br /><br />Unmount and do the migration to ext4 (as described in the ext4 wiki and numerous other sites)<br /><span style="font-style:italic;">#umount /mnt/root/<br />#tune2fs -O extents,uninit_bg,dir_index /dev/tlap/root<br />#e2fsck -pfD /dev/tlap/root</span><br /><br />Mount new ext4 disk and change fstab to ext4<br /><span style="font-style:italic;">#mount /dev/tlap/root /mnt/root<br />#cd /mnt/root/etc/<br />#vi fstab</span><br /><br />Change ext3 to ext4 for you / disk (/dev/sda1 for me).<br /><span style="font-style:italic;"># /dev/mapper/tlap-root<br />UUID=ca86bf3d-40fb-4b4d-89c6-15ce94674fa0 / ext4 relatime,errors=remount-ro 0 1<br /></span><br />Save, unmount /mnt/root and reboot.<br />After reboot check /etc/fstab and 'mount' and you will see that it's ext4 now.<br /><br /><span style="font-style:italic;">tomas@tlap:~/tmp$ mount<br />/dev/mapper/tlap-root on / type ext4 (rw,relatime,errors=remount-ro)<br />tmpfs on /lib/init/rw type tmpfs (rw,nosuid,mode=0755)<br />...</span><br /><br /><span style="font-weight:bold;">Update:</span><br />I migrated my rather slowish home computer (AMD 4200+, 4GB, WD Raptor) running 'ant clean; ant' both before and after migration. The conclusion is that it takes 1 minute, give or take a few seconds, on both ext3 and ext4. Not huge leaps in speed there unfortunately.<div class="blogger-post-footer"><img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/7933348372264971621-6257434391672573655?l=blog.ejbca.org'/></div>tomashttp://www.blogger.com/profile/15030707839569169791noreply@blogger.com1tag:blogger.com,1999:blog-7933348372264971621.post-4637403235940038062009-04-23T15:56:00.001+02:002009-04-23T15:58:14.421+02:00What to do when you mac address of eth0 changed (debian/ubuntu)?It always takes me too long to google up this answer so I'll write it here..<br /><br />Either edit or delete this file:<br />/etc/udev/rules.d/70-persistent-net.rules<br /><br />If you delete it, a reboot will create a new one with your new mac address.<div class="blogger-post-footer"><img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/7933348372264971621-463740323594003806?l=blog.ejbca.org'/></div>tomashttp://www.blogger.com/profile/15030707839569169791noreply@blogger.com0tag:blogger.com,1999:blog-7933348372264971621.post-61689460394546436192009-04-14T14:43:00.003+02:002009-04-14T14:49:21.185+02:00External RA improvementsIn the upcoming EJBCA 3.9 the External RA is finally getting some long waited improvements.<br />The CA component will now run as a service in EJBCA. This means that you do most of the configuration in the admin-GUI of EJBCA and that it runs very nicely in a CA cluster. You can also configure multiple external RAs, as many as you need. <br />Setting up a cluster of external RAs is now very simple, if you have a cluster of two external RAs simply configure two external RA services in EJBCA and you're done. No need to use complicated database clusters etc on the external RAs, each external RA node can be simple and stand-alone.<br /><br />Installation of the external RA is also much much simpler now. Configure the path to the external RA package in EJBCA and the needed CA service is automatically pulled into EJBCA so it is available to be configured in the Admin-GUI. The only thing that needs some though is the configuration of datasources in your application server.<br /><br />To summarize:<br />- Easier to install and configure<br />- Runs nice in a CA cluster<br />- Runs nice against multiple external RAs<br /><br />As an added bonus, it's also now almost trivial for developers to implement new types of external RA messages. Internally it uses java reflection, so all you have to do is implement the message classes and handlers. The rest is handled automatically.<div class="blogger-post-footer"><img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/7933348372264971621-6168946039454643619?l=blog.ejbca.org'/></div>tomashttp://www.blogger.com/profile/15030707839569169791noreply@blogger.com0tag:blogger.com,1999:blog-7933348372264971621.post-60811484179179831042009-03-28T00:29:00.000+01:002009-03-28T00:37:17.096+01:00EJBCA 3.8.2 released"This is a minor release adding improvements and bugfixes<br />- Add street and pseudonym DN attributes.<br />- OCSP improvements, RFC 5019, nextUpdate, support for requests using GET, improved configuration and error handling.<br />- Correct coding of optional Issuing Distribution Point in CRLs.<br />- Possible to publish userPassword in LDAP.<br />- A few minor fixes."<br />Check out the change-log for all the details.<br /><br />A pretty cool feature that hides behind the "RFC 5019" improvement is that you can now cache OCSP responses. If you use HTTP GET you will be able to use simple network components like a HTTP/1.1 cache (Apache httpd config included in the docs) for caching and load-balancing between your responders. I'd love to see someone try this out on a massive scale and report back to me with some statistics.. =)<div class="blogger-post-footer"><img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/7933348372264971621-6081148417917983104?l=blog.ejbca.org'/></div>johanhttp://www.blogger.com/profile/13040946118364095991noreply@blogger.com0tag:blogger.com,1999:blog-7933348372264971621.post-28757244925161615862009-02-03T12:36:00.002+01:002009-02-03T12:44:14.628+01:00Using smart card browser authentication in UbuntuTo use smart card authentication in Firefox on Ubuntu 8.10 you have to install pcscd, a working card reader driver (if the built in ccid does not work for you) and a pkcs#11 module.<br /><br />This example works for Ubuntu 8.10. In my case I have an OmniKey CardMan 3021 USB card reader and a smart card with 2048 bit RSA keys. To be able to use 2048 bit keys using the OmniKey reader I have to use their driver.<br /><br />- Download driver from omnikey.com and put in /tmp<br /><br /># sudo su -<br /># apt-get install pcscd<br /># cd /tmp<br /># tar -zxvf ifdokccid_lnx_x64-3.5.1.tar.gz<br /># cd /usr/lib/pcsc/drivers<br /># cp -r /tmp/ifdokccid_lnx_x64-3.5.1/ifdokccid_lnx_x64-3.5.1.bundle .<br /># rm -rf ifd-ccid.bundle/<br /># /etc/init.d/pcscd restart<br /># apt-get install mozilla-opensc<br /><br />Finally open pkcs11.html in Firefox and click "Install opensc in linux".<br /><br />--- pkcs11.html ---<br />&lt;HTML><br />&lt;HEAD><br /> &lt;TITLE>opensc&lt;/TITLE><br />&lt;/HEAD><br />&lt;BODY><br />&lt;SCRIPT><br /> PKCS11_PUBLIC_READ_CERT = 0x1<<28;<br /> function doInstallPkcs11Windows()<br /> {<br /> pkcs11.addmodule("opensc", "opensc-pkcs11.dll", PKCS11_PUBLIC_READ_CERT, 0);<br /> }<br /> function doInstallPkcs11Linux()<br /> {<br /> pkcs11.addmodule("opensc", "opensc-pkcs11.so", PKCS11_PUBLIC_READ_CERT, 0);<br /> }<br /> function doUninstallPkcs11()<br /> {<br /> pkcs11.deletemodule("opensc");<br /> }<br />&lt;/SCRIPT><br />&lt;a href=javascript:doInstallPkcs11Linux();>Install opensc in Linux&lt;/a>&lt;br><br />&lt;a href=javascript:doInstallPkcs11Windows();>Install opensc in Windows&lt;/a>&lt;br><br />&lt;a href=javascript:doUninstallPkcs11();>Uninstall opensc&lt;/a>&lt;br> <br />&lt;/BODY><br />&lt;/HTML><div class="blogger-post-footer"><img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/7933348372264971621-2875724492516161586?l=blog.ejbca.org'/></div>tomashttp://www.blogger.com/profile/15030707839569169791noreply@blogger.com0tag:blogger.com,1999:blog-7933348372264971621.post-1996716560564155682009-01-29T12:43:00.002+01:002009-01-29T12:51:25.956+01:00EJBCA 3.8.1 releasedThis is a minor release, targeted for adding support for JBoss 5 and fixing a mistake that caused install on Glassfish to fail. <br />It also adds a few minor improvements and bugfixes. <br />- Add support for JBoss 5. <br />- Fix support for Glassfish caused by a forgotten commit in 3.8.0. <br />- Improve support for Weblogic 10.3. <br />- Fix support for IPv6 subject alternative names. <br />- A few minor CMP, OCSP and CVC fixes. <br /><br />See the full changelog at <a href="http://ejbca.org/">ejbca.org</a> for details.<div class="blogger-post-footer"><img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/7933348372264971621-199671656056415568?l=blog.ejbca.org'/></div>tomashttp://www.blogger.com/profile/15030707839569169791noreply@blogger.com0tag:blogger.com,1999:blog-7933348372264971621.post-52367793467572025092008-12-20T17:25:00.006+01:002008-12-28T13:22:32.136+01:00HTC G1 android phone and tele2Hardly surprising the G1 works perfectly also in sweden. To configure for tele2 I only configured five items in the APN configuration.<br />- Name: Tele2<br />- APN: internet.tele2.se<br />- MMSC: http://mmsc.tele2.se<br />- MMS proxy: 130.244.202.30<br />- MMS port: 8080<br />After this this phone works like a charm. Buying the phone from google was easy and delivery was fast, only a week.<br />Now all we have to do is run EJBCA on the phone :-)<br /><br />To re-encode movies to show on the phone (using cinema app for example) do this on Ubuntu:<br />- apt-get install avidemux, and start avidemux. Avidemux works great as a mobile media encoder.<br />- Open the file you want to convert.<br />- In Video dropdown select MGEG-4 ASP (lavc).<br />- Click Configure->Encoding Mode->Single pass - bitrate, enter 384 kb/s and click ok. <br />- Click Filters, double click MPlayer resize, width 480, height 320, click OK then close.<br />- In Audio dropdown select AAC (FAAC).<br />- Click Configure and select bitrate 96.<br />- In Format dropdown select MP4.<br />- Finally click Save and enter the new filename with .mp4 ending.<br /><br />Now just make sure you copy the file to sdcard intact.<div class="blogger-post-footer"><img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/7933348372264971621-5236779346757202509?l=blog.ejbca.org'/></div>tomashttp://www.blogger.com/profile/15030707839569169791noreply@blogger.com7tag:blogger.com,1999:blog-7933348372264971621.post-63551871779319473452008-12-16T14:26:00.004+01:002008-12-16T14:30:43.208+01:00Zepto Nox A15 and Ubuntu 8.10On my new Zepto Nox A15 most things work out of the box, except suspend to ram (hibernate works) and screen brightness. I blame the nvidia proprietary driver for this...<br /><br />This is what I did to get screen brighness settings to work:<br />-----<br />First check out the latest nvclock source code:<br />> cvs -d:pserver:anonymous@nvclock.cvs.sourceforge.net:/cvsroot/nvclock login<br />> cvs -z3 -d:pserver:anonymous@nvclock.cvs.sourceforge.net:/cvsroot/nvclock co -P nvclock<br />> cd nvclock<br />> gedit src/backend/nv50.c<br />change line 331 from:<br />if((nv_card->subvendor_id == PCI_VENDOR_ID_SONY) &amp;&amp; nv_card->gpu == MOBILE)<br />to<br />if(nv_card->gpu == MOBILE)<br />> ./configure --prefix=/usr<br />> make<br />> sudo make install<br />> sudo cp src/smartdimmer /usr/bin/smartdimmer<br /><br />Now we have the command so fix up hal so it calls nvclock when the brightness keys on the keyboard are pressed:<br />> sudo gedit /usr/lib/hal/scripts/linux/hal-system-lcd-set-brightness-linux<br /><br />if [ -w "$HAL_PROP_LINUX_SYSFS_PATH/brightness" ]; then<br /> echo "$value" > $HAL_PROP_LINUX_SYSFS_PATH/brightness<br /> if [ "$HAL_PROP_LAPTOP_PANEL_ACCESS_METHOD" = "general" ]; then<br /> # if nvidia nvclock command exists, try to use it<br /> if command -v nvclock &amp;>/dev/null<br /> then<br /> #echo " Yes, command :nvclock: was found."<br /> foo="$(((($value +1)*10)+5))"<br /> nvclock -S $foo<br /> fi<br /> fi<br /> exit 0<br />fi<br />-----<br /><br />Done. Now if only suspend would work it would be perfect.<br />I also have some slight problems with sound settings (volume up/down) that worked at first but not anymore...<br /><br />Oh I forgot to say...EJBCA works perfect!<div class="blogger-post-footer"><img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/7933348372264971621-6355187177931947345?l=blog.ejbca.org'/></div>tomashttp://www.blogger.com/profile/15030707839569169791noreply@blogger.com8tag:blogger.com,1999:blog-7933348372264971621.post-7556353944128259462008-12-16T14:12:00.003+01:002008-12-21T18:14:22.996+01:00EJBCA 3.8.0 releasedEJBCA 3.8.0 have a whole range of fixes. One of the most interesting is the improvements in the authorization module, making it much easier to configure administrators and allowing you to use externally issued certificates as administrator certificates (for example from a national id).<br />This will hopefully get rid of most questions posted asking about problems configuring new administrators.<br /><br />See <a href="http://ejbca.org/">http://ejbca.org/</a> for the download and full changelog.<br /><br />News was published on <a href="http://www.theserverside.com/news/thread.tss?thread_id=52438">Serverside.com</a>.<div class="blogger-post-footer"><img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/7933348372264971621-755635394412825946?l=blog.ejbca.org'/></div>tomashttp://www.blogger.com/profile/15030707839569169791noreply@blogger.com0tag:blogger.com,1999:blog-7933348372264971621.post-78715659199947219192008-11-19T14:24:00.006+01:002008-11-19T14:35:18.659+01:00Simple Certificate Archival solution<h1 style="font-weight: normal;">Introduction</h1><br />From syscheck 1.2 and on there is a script-based archival solution.<br /><br />New and revoked certificates are stored on local disk in a file-tree and optional remote SSH server.<br /><br />syscheck svn: https://ejbca.svn.sourceforge.net/svnroot/ejbca/trunk/syscheck/<br /><h1 style="font-weight: normal;">Setup of publisher</h1><br />Go to: EJBCA Adminweb → ”<a href="https://localhost:8443/ejbca/adminweb/ca/editpublishers/editpublishers.jsp" target="mainFrame">Edit Publishers</a>” → Add new name: ”Archival publisher”<br /><br /><p><br />Select/ enter the following:<br /><br /><br /><b>Publisher Type:</b> ”Custom Publisher”<br /><br /><b>Class Path:</b> ”org.ejbca.core.model.ca.publisher.GeneralPurposeCustomPublisher”</p> <p style="margin-bottom: 0cm;"></p><p style="margin-bottom: 0cm; text-decoration: none;" align="LEFT"><b>Properties of Custom Publisher: </b> </p> <p style="margin-bottom: 0cm;">crl.application /path/to/syscheck/related-enabled/902_export_crl.sh</p> <p style="margin-bottom: 0cm;">crl.failOnStandardError true</p> <p style="margin-bottom: 0cm;">crl.failOnErrorCode true</p> <p style="margin-bottom: 0cm;">cert.application /path/to/syscheck/related-enabled/900_export_cert.sh</p> <p style="margin-bottom: 0cm;">cert.failOnStandardError true</p> <p style="margin-bottom: 0cm;">cert.failOnErrorCode true</p> <p style="margin-bottom: 0cm;">revoke.application /path/to/syscheck/related-enabled/901_export_revocation.sh</p> <p style="margin-bottom: 0cm;">revoke.failOnStandardError true</p> <p style="margin-bottom: 0cm;">revoke.failOnErrorCode true</p> <p style="margin-bottom: 0cm;"><span style="font-size:180%;">Use the publisher on CA:s</span></p> <p style="margin-bottom: 0cm;">Go to: EJBCA Adminweb → ”Edit Certificate Authorites”</p> <p style="margin-bottom: 0cm;">Select the CA you want CRL archival on, then click on edit CA</p> <p style="margin-bottom: 0cm;">At ”CRL Publishers”:</p> <p style="margin-bottom: 0cm;">Select ”Archival publisher”</p> <p style="margin-bottom: 0cm;">Do this for all CA:s you want CRL Archival for.</p> <p style="margin-bottom: 0cm;"><span style="font-size:180%;">Use the publisher on Certificate profile:s</span></p> <p style="margin-bottom: 0cm;">Go to: EJBCA Adminweb → ”Edit Certifcate Profiles”</p> <p style="margin-bottom: 0cm;">At: ”Publishers”</p> <p style="margin-bottom: 0cm;">Select ”Archival publisher”</p> <p style="margin-bottom: 0cm;">Do this for all Certificate profiles:s you want Certifcate Archival for.</p><p style="margin-bottom: 0cm;"><br /></p><div class="blogger-post-footer"><img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/7933348372264971621-7871565919994721919?l=blog.ejbca.org'/></div>kinnehhttp://www.blogger.com/profile/09969862732229368860noreply@blogger.com1tag:blogger.com,1999:blog-7933348372264971621.post-28949734425874694882008-10-31T10:07:00.002+01:002008-10-31T10:13:15.561+01:00Presentation from FSCONSJohan and Tham went to FSCONS 2008 and presented "Secure communication with open source PKI". It's a basic introduction to PKI and a demonstration of email-signing, Apache client cert authentication and using certs in OpenVPN.<br /><br /><iframe class="forma" src="http://giss.tv/dmmdb//player.php?ID=531" height="288" width="360"></iframe><br /><br /><a href="http://giss.tv/dmmdb/contents/pki-dl.ogg">Direct link to the video</a> (use VLC to play it if it doesn't work).<br /><br /><a href="http://download.primekey.se/public/fscons2008-pki.pdf">The presentation slides.</a><div class="blogger-post-footer"><img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/7933348372264971621-2894973442587469488?l=blog.ejbca.org'/></div>johanhttp://www.blogger.com/profile/13040946118364095991noreply@blogger.com0tag:blogger.com,1999:blog-7933348372264971621.post-62419896011900913722008-10-27T10:37:00.002+01:002008-10-27T10:41:32.545+01:00EJBCA and BouncyCastle on OSOR.eu eID/PKI/eSignature Community WorkshopI will present a "Lightening talk" on the OSOR.eu eID/PKI/eSignature Community Workshop in Brussels on the 13th of November 2008. The talk will be a short one describing experience from both the BouncyCastle and the EJBCA projects regarding open source usage in the EU. The hope is to give some input what the EU can do to help, or not to discriminate, open source projects/products.<br />The BouncyCastle part is made by David Hook of <a href="http://www.lockboxlabs.com/">Lockboxlabs</a>.<div class="blogger-post-footer"><img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/7933348372264971621-6241989601190091372?l=blog.ejbca.org'/></div>tomashttp://www.blogger.com/profile/15030707839569169791noreply@blogger.com0tag:blogger.com,1999:blog-7933348372264971621.post-21525149253488141442008-10-13T10:04:00.003+02:002008-10-13T10:16:20.279+02:00Presentation from Open Standards ForumYou can read and view my presentation from Oasis Open Standards Forum that took place in London in the beginning of October. The event was very interesting, a lot is happening in the standardization and technology arena.<br /><br />Presentation <a href="http://download.primekey.se/oasis/OpenStandardsForum2008-XML_PKI_MgmgProtocols_CaseStudy-oasis.pdf">slides</a>.<br /><br />Presentation <a href="http://download.primekey.se/oasis/Tomas_on_PKI_at_OASIS_FORUM_2008.mp4">movie</a> (73MB).<div class="blogger-post-footer"><img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/7933348372264971621-2152514925348814144?l=blog.ejbca.org'/></div>tomashttp://www.blogger.com/profile/15030707839569169791noreply@blogger.com0tag:blogger.com,1999:blog-7933348372264971621.post-37366184226580280822008-10-08T14:28:00.003+02:002008-10-08T14:32:45.744+02:00EJBCA @ FSCONS 2008Two core EJBCA developers from <a href="http://www.primekey.se">PrimeKey Solutions AB</a> will be present at this years <a href="http://fscons.org">FSCONS</a> (2008-10-24 to 26th). Since PrimeKey sponsors the conference, we will have a booth somewhere in "the lounge area". So drop by and ask questions about the latest and greatest, suggest new features or tell us how you want to use EJBCA.<br /><br />It currently looks like we get a chance to talk the last day at 16:00 on the subject "Secure communications with Open Source PKI". The preliminary plan is to give a simple hands-on presentation on how easy PKI can be used for secure email, client SSL authentication, OpenVPN and more.<br /><br />We hope to see you all there!<div class="blogger-post-footer"><img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/7933348372264971621-3736618422658028082?l=blog.ejbca.org'/></div>johanhttp://www.blogger.com/profile/13040946118364095991noreply@blogger.com0tag:blogger.com,1999:blog-7933348372264971621.post-31750221953114570242008-09-14T11:40:00.003+02:002008-09-14T11:44:02.343+02:00Succesful EAC ePassport PKI interoperability testsEJBCA was present on the Prague event for PKI interoperability tests, since both Sweden and Portugal uses EJBCA for their EAC CVC PKI. The tests were a huge success and no problems were encountered in EJBCA. Interoperability was tested with many different countries using different implementations and algorithms.<br /><br />Look out for EJBCA 3.7.1, that will bring ECC support (as tested on the event) and a lot of CVC usability enhancements.<div class="blogger-post-footer"><img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/7933348372264971621-3175022195311457024?l=blog.ejbca.org'/></div>tomashttp://www.blogger.com/profile/15030707839569169791noreply@blogger.com0tag:blogger.com,1999:blog-7933348372264971621.post-71633693562948604202008-09-06T17:29:00.004+02:002008-09-06T17:31:20.601+02:00Bouncycastle supported by Lock Box LabsMy favorite open source project, the Java crypto provider Bouncycastle (<a href="http://www.bouncycastle.org/">http://www.bouncycastle.org/</a>) have gotten their own legal entity offering support contracts. Go get one!<div class="blogger-post-footer"><img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/7933348372264971621-7163369356294860420?l=blog.ejbca.org'/></div>tomashttp://www.blogger.com/profile/15030707839569169791noreply@blogger.com0tag:blogger.com,1999:blog-7933348372264971621.post-11848667142127135462008-09-01T14:07:00.000+02:002008-09-01T14:08:02.158+02:00Cert-cvc library 1.2.7 releasedThis release of the CV certificate library, for EAC 1.11 ePassports, contains full support for both RSA and ECC algorithms.<br /><br />This marks another milestone for ePassport support in EJBCA. The cert-cvc library now has full support and can be freely used by anyone under the LGPLv2 license.<br /><br />Changes:<br />- Support for ECC keys and signatures, need BC version 1.41 which is included in svn.<br />- Fix bug where outer signature in authenticated requests did not include CARef in TBS<br />- Don't add caRef if not passed, or passed as null, to CertificateGenerator.<br />- Translations of Swedish javadoc to English.<br /><br /><br />Cheers,<br />Tomas<div class="blogger-post-footer"><img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/7933348372264971621-1184866714212713546?l=blog.ejbca.org'/></div>tomashttp://www.blogger.com/profile/15030707839569169791noreply@blogger.com0tag:blogger.com,1999:blog-7933348372264971621.post-59591293367554763802008-08-13T14:51:00.003+02:002008-08-13T15:07:59.557+02:00Oasis Open Standards Forum in LondonOn the 30th of September to 3rd of October Oasis will hold Open Standard Forum near London. For more information see the official <a href="http://events.oasis-open.org/home/forum/2008/">website</a>.<br /><br />I'm also excited about listening to the other speakers at the event, covering many different areas of identity- and key management.<br /><br />I have been accepted as a speaker and will talk about XML protocol interfaces to a PKI. I will mostly use case studies to kind of outline the requirements of an XML protocol. The most detailed case study is the Hardtoken Management Framework developed by Philip in cooperation with the Swedish police (<a href="http://www.hardtokenmgmt.org/">www.hardtokenmgmt.org</a>). The hardtoken management framework is the basis for the smart card management at the Swedish police and uses Webservice interface to communicate with the PKI.<br />On interesting topic, where we might receive some feedback(?), is what happened to XKMS and if there is any future efforts in that direction. Also looking more into the future we may see a merging of symmetric key management (EKMI) and PKI management.<br /><br />Maybe we'll see some standardization in this area?<br /><br />If you have your ways pass London you should join.<div class="blogger-post-footer"><img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/7933348372264971621-5959129336755476380?l=blog.ejbca.org'/></div>tomashttp://www.blogger.com/profile/15030707839569169791noreply@blogger.com0tag:blogger.com,1999:blog-7933348372264971621.post-51127721692954768242008-07-11T15:46:00.002+02:002008-07-11T15:51:24.357+02:00EJBCA gets ePassport contribution from Swedish National Police BoardThe open source enterprise PKI software EJBCA has received support for EU EAC ePassports. The Swedish National Police Board has developed the cert-cvc java library used for the implementation, and contributes the library to the open source project under the LGPL license. The Police Board also supported the development to integrate the library into EJBCA.<br /><br />EAC, short for Extended Access Control, is the standard developed in the EU to protect fingerprint and iris data stored on electronic travel documents (passports). Fingerprints will be stored on all EU passport within a few years, with pilot project starting this year. Releasing the library to the open source means that other EU member states does not have to develop everything themselves, and could make implementation much easier and less expensive.<br />A perfect example of openness and cooperation.<br /><br />This release is feature complete for EU EAC ePassports using RSA algorithm. ECC support is still not complete. Any help in the ECC area is welcome.<br /><br />The library is released, with full source, and can be downloaded from sourceforge — <a href="http://sourceforge.net/projects/ejbca/" rel="nofollow">http://sourceforge.net/projects/ejbca/</a>."<div class="blogger-post-footer"><img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/7933348372264971621-5112772169295476824?l=blog.ejbca.org'/></div>tomashttp://www.blogger.com/profile/15030707839569169791noreply@blogger.com0tag:blogger.com,1999:blog-7933348372264971621.post-80659260974475975302008-07-05T19:47:00.002+02:002008-07-05T19:50:26.081+02:00EJBCA HA best practicesThere are many ways to design a HA system taking all considerations into account. After dealing with this issue for a couple of years, here is our teams experience on what works and what doesn't work.<br /><br />There are two important components in a HA EJBCA setup:<br /><ul><li>Database</li><li>EJBCA application server</li></ul>The database is by far the trickiest to set up in HA-mode. The database holds everything that is really important in an EJBCA setup.<br />In case of failure, everything can be re-created from the EJBCA distribution except the database contents.<br />A full HA setup would look like:<br /><ul><li>Load balancers in front of the EJBCA app servers</li><li>EJBCA app servers using a single HA database on a single ip</li><li>Load balancers in front of the database cluster</li><li>A HA database cluster</li></ul>This is of course expensive and this setup is suitable for organizations with dedicated database/app server/load balancer groups that have the resources and knowledge to handle this kind of system.<br /><br />Most shops however simply don't want, don't need, or can't handle that kind of complexity.<br /><br />Another alternative, that does not provide full HA, but that does provide very good data safety with short fail over times is:<br /><ul><li>Two combined EJBCA/database servers with three ip's, one real for each server and one "virtual" that can be moved.</li><li>Node 1 has the virtual ip by default.</li><li>Database master on node 1 that replicates, in real time, to node 2.</li><li>EJBCA running on both nodes using the "virtual" ip as database ip.</li><li>If node 1 fails, a script must be manually run that changes the virtual ip to node 2, and restarts app server on node 2. Now node 2 is master and single point of failure while node 1 is brought up again.</li><li>When node 1 is brought up again the system is either restored to original state with node 1 as master (requires restoring database on node 1 and reseting replication), or node 2 is now the master and replicates to node 1 (requires starting replication in that direction).</li></ul>Other alternatives that you might start to look at is to include software load balancers and automatic fail-over scripts in the combined servers.<br /><span style="font-style: italic;">In our experience this is not a good idea!</span><br />In most cases this setup will cause more problems than it solves and your issues will originate from the load balancing software/fail-over scripts not working instead of the database/EJBCA not working.<br />If you are not sure what you are doing and has done this kind of setups several times before, stay away from it.<div class="blogger-post-footer"><img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/7933348372264971621-8065926097447597530?l=blog.ejbca.org'/></div>tomashttp://www.blogger.com/profile/15030707839569169791noreply@blogger.com0