bloovis.com

03/25/2010 (8:02 pm)

Moving from Keyring on Palm to KeePass on Linux and Android

Filed under: android,centro,linux,nexus one ::

Keyring is a fine little open source application for Palm OS that stores and generates passwords. There is no Android version of this program, so I decided to move to KeePass 1.x, both the Linux version and the Android version.

Then I hunted for way to import my Keyring data into KeePass 1.x. I couldn’t find a tool to do this, so I had to invent my own method, which included writing a conversion script in Ruby.

The first step is to generate an XML version of the Keyring data file, using this Java program. I fed it the Keyring data, a file called Keys-Gtkr.pdb that I had previously backed up onto my Linux machine using pilot-xfer. It produced the XML equivalent, which I redirected to a file.

Then I wrote a Ruby script called kr2kp, which reads the Keyring XML file and outputs KeePass-compatible XML. I saved the output of this script to another file.

The Android version of KeyPass doesn’t import XML, so I turned to the Linux version, and used it to import the XML file I had created in the previous step. Then I saved the resulting database into a file called keyring.kdb.

Next, I copied keyring.kdb to the keepass directory on the Android device’s SD card. (The exact path of the SD card will depend on the directory where your computer mounts the SD card when you connect the Android device via USB.)

Finally, I ran the Android KeePass app and opened the keyring.kdb file. The Android app is somewhat limited, and doesn’t let you move entries between groups or rename groups. So that kind of manipulation has to be done on the Linux side, and then the .kdb file has to be copied to the Android SD card, as described above.

8 Responses to “Moving from Keyring on Palm to KeePass on Linux and Android”

  1. Links 28/3/2010: Sabayon 5.2 and GIMP Fun | Boycott Novell Says:

    [...] Moving from Keyring on Palm to KeePass on Linux and Android [...]

  2. trxcan Says:

    I have this error with your ruby script:

    kr2kp.rb:30: undefined method `content’ for nil:NilClass (NoMethodError)
    from kr2kp.rb:27:in `each’
    from kr2kp.rb:27

  3. admin Says:

    It sounds like there’s an entry in your keyring file that doesn’t have a username.
    I’ll update the script to check for this.

  4. trxcan Says:

    Thank you very much! I put username in all empty entry and it work.

  5. Max Says:

    Thank you so much! I’ve been stuck on keyring years after I stopped using my palm for anything else. I’ve finally broken free and your ruby script was critical!

  6. amette Says:

    Same situation here as with Max!! Thanks a bunch for freeing me from KeyRing!!! :))

  7. irwan Says:

    This post helped me a bunch migrating from keyring. Thanks man!

  8. KevAvatar Says:

    My Palm m505 is still working just fine after 12 years of service, but obviously I am at least 5 years overdue for moving Keyring functionality onto something else. I’ve used the m505 along with J-Pilot for a while to have 21st century access abilities. Both Keyring and J-Pilot are great products and I would have been delighted to see them evolve. Android KeePass is the obvious successor to these products.

    Your Ruby script made my transition easy and painless, THANK YOU! I’m grateful that you posted your script and instructions, and that you’ve kept bloovis.com available with this info.

    I hope I can contribute with a footnote about the http://gnukeyring.sourceforge.net/conduits.html Java program. If you’re careful&|paranoid like me you’ll want to examine the Java source and compile it from scratch. The export-src.jar is missing KeyringEntry.java. You can get this from many sources, check Google, and drop it into ./net/sf/gnukeyring/KeyringEntry.java; then javac your own binary of the code.

    ~K

Leave a Reply