#!/usr/bin/perl -w # $Id: ascii-key-splitter,v 1.1 2002/01/15 22:37:50 jason Exp jason $ # splits keyring file into chunks in ./tmp... # chunks can then be fed to pksclient add to import into a pks db # or selectively fed to gpg --import for a personal keyring... die if (-e "./tmp"); mkdir "./tmp", 0700 || die; $/ = "-----END PGP PUBLIC KEY BLOCK-----"; # record separator $i = 0; while () { open (OUT, "> ./tmp/key.$i") || die; print OUT $_ . "\n"; close OUT; $i++; }