标签:request methods googl sql method code cookie font class
use Net::HTTP::Request;
use Net::HTTP::URL;
use Net::HTTP::Transport;
my $url = Net::HTTP::URL.new("http://localhost/sqli-labs-master/Less-1/?id=2%");
my $request = Net::HTTP::Request.new(:$url, :method<POST>, header => {:Host<google.com>,:cookie<abcde=1>}, body => ‘abcde‘);
say $request.WHAT;
say $request.Str;
say $request.^methods;
my $transport = Net::HTTP::Transport.new;
my $response = $transport.round-trip($request);
say $response.body.decode(‘utf-8‘);
Net::HTTP 一次添加 cookie, body 发送post请求
标签:request methods googl sql method code cookie font class
原文地址:https://www.cnblogs.com/perl6/p/9565210.html