in reply to CX or System

There are several CPAN modules available right now that will parse XML for you into a Perl data structure, such as XML::Simple. While your approach works for your needs, consider "doing it the right way" by parsing the XML file into a data structure and pull the proper piece of data out, all within the context of your code, not your code and several other forked processes (cut, grep, etc.).

# the following is untested use strict; use warnings; use XML::Simple; use Data::Dumper; my $xml = XMLin( '/opt/SecureSphere/etc/bootstrap.xml' ); my $db = $xml->{path}{to}{db}; print Dumper $db; my $pass = `password_decode $db`; print "$pass\n";

jeffa

L-LL-L--L-LL-L--L-LL-L--
-R--R-RR-R--R-RR-R--R-RR
B--B--B--B--B--B--B--B--
H---H---H---H---H---H---
(the triplet paradiddle with high-hat)