4 # Put Username and password into to /etc/sysconfig/donkey
8 # HTTPPASS=yourpassword
10 my $cfg = "/etc/sysconfig/donkey";
11 open(I
,"<$cfg") || die "Can't read $cfg: $!\n";
12 chomp (my @lines = (<I
>));
16 if (/([^=\s]+)=([^=\s]+)/) {
20 my $ua = LWP
::UserAgent
->new;
21 my $req = HTTP
::Request
->new(GET
=> 'http://localhost:4080/submit?q=kill');
22 if (($vars{'HTTPUSER'}) && ($vars{'HTTPPASS'})) {
23 $req->authorization_basic($vars{'HTTPUSER'}, $vars{'HTTPPASS'});