use the pack function... i.e. pack("H*", $value) andy Jay Austad wrote: > This should be really simple, but, I did a db_dump from the Berkely > DB database off my phone, and everything is encoded in hex values, > strings that look like this: > > 87474703a2f2f3231362e3135352e3137342e38342f736572766c6574732f6d6d733f6d6 > 573736167652d69 > > I decoded some of it by hand, and it has the info I need. I just > need a perl script to run over the dump file and convert ever two > characters into their ascii equivalent, and since it's been awhile > since I did any perl, I'm at a loss of how to do it. > > Note that there are spaces and newlines in this file (which are not > encoded into hex), so the counting for every two characters has to > start at the beginning of each hex string. > > Any ideas? Even a perl one-liner that I could use would work: > > cat native.dump | perl -nle '<something>' > > > > _______________________________________________ > TCLUG Mailing List - Minneapolis/St. Paul, Minnesota > tclug-list at mn-linux.org > http://mailman.mn-linux.org/mailman/listinfo/tclug-list -- CEMS IT Office 185 Amundson Hall (612)-626-0712 https://www1.cems.umn.edu/dept/itoffice/