亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關于我們
? 蟲蟲下載站

?? client.pm

?? 網頁留言本,比一般的留言簿管用
?? PM
字號:
# $Id: Client.pm 4536 2004-05-11 05:33:05Z btrott $package XML::Atom::Client;use strict;use XML::Atom;use base qw( XML::Atom::ErrorHandler );use LWP::UserAgent;use XML::Atom::Entry;use XML::Atom::Feed;use XML::Atom::Util qw( first textValue );use Digest::SHA1 qw( sha1 );use MIME::Base64 qw( encode_base64 );use DateTime;use constant NS_ATOM => 'http://purl.org/atom/ns#';use constant NS_SOAP => 'http://schemas.xmlsoap.org/soap/envelope/';sub new {    my $class = shift;    my $client = bless { }, $class;    $client->init(@_) or return $class->error($client->errstr);    $client;}sub init {    my $client = shift;    my %param = @_;    $client->{ua} = LWP::UserAgent::AtomClient->new($client);    $client->{ua}->agent('XML::Atom/' . XML::Atom->VERSION);    $client;}sub username {    my $client = shift;    $client->{username} = shift if @_;    $client->{username};}sub password {    my $client = shift;    $client->{password} = shift if @_;    $client->{password};}sub use_soap {    my $client = shift;    $client->{use_soap} = shift if @_;    $client->{use_soap};}sub auth_digest {    my $client = shift;    $client->{auth_digest} = shift if @_;    $client->{auth_digest};}sub getEntry {    my $client = shift;    my($url) = @_;    my $req = HTTP::Request->new(GET => $url);    my $res = $client->make_request($req);    return $client->error("Error on GET $url: " . $res->status_line)        unless $res->code == 200;    XML::Atom::Entry->new(Stream => \$res->content);}sub createEntry {    my $client = shift;    my($uri, $entry) = @_;    return $client->error("Must pass a PostURI before posting")        unless $uri;    my $req = HTTP::Request->new(POST => $uri);    $req->content_type('application/x.atom+xml');    my $xml = $entry->as_xml;    $req->content_length(length $xml);    $req->content($xml);    my $res = $client->make_request($req);    return $client->error("Error on POST $uri: " . $res->status_line)        unless $res->code == 201;    $res->header('Location') || 1;}sub updateEntry {    my $client = shift;    my($url, $entry) = @_;    my $req = HTTP::Request->new(PUT => $url);    $req->content_type('application/x.atom+xml');    my $xml = $entry->as_xml;    $req->content_length(length $xml);    $req->content($xml);    my $res = $client->make_request($req);    return $client->error("Error on PUT $url: " . $res->status_line)        unless $res->code == 200;    1;}sub deleteEntry {    my $client = shift;    my($url) = @_;    my $req = HTTP::Request->new(DELETE => $url);    my $res = $client->make_request($req);    return $client->error("Error on DELETE $url: " . $res->status_line)        unless $res->code == 200;    1;}sub getFeed {    my $client = shift;    my($uri) = @_;    return $client->error("Must pass a FeedURI before retrieving feed")        unless $uri;    my $req = HTTP::Request->new(GET => $uri);    my $res = $client->make_request($req);    return $client->error("Error on GET $uri: " . $res->status_line)        unless $res->code == 200;    my $feed = XML::Atom::Feed->new(Stream => \$res->content)        or return $client->error(XML::Atom::Feed->errstr);    $feed;}sub make_request {    my $client = shift;    my($req) = @_;    $client->munge_request($req);    my $res = $client->{ua}->request($req);    $client->munge_response($res);    $res;}sub munge_request {    my $client = shift;    my($req) = @_;    $req->header(        Accept => 'application/x.atom+xml, application/xml, text/xml, */*',    );    my $nonce = $client->make_nonce;    my $nonce_enc = encode_base64($nonce, '');    my $now = DateTime->now->iso8601 . 'Z';    my $digest = encode_base64(sha1($nonce . $now . ($client->password || '')), '');    if ($client->use_soap) {        my $xml = $req->content || '';        $xml =~ s!^(<\?xml.*?\?>)!!;        my $method = $req->method;        $xml = ($1 || '') . <<SOAP;<soap:Envelope  xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/"  xmlns:wsu="http://schemas.xmlsoap.org/ws/2002/07/utility"  xmlns:wsse="http://schemas.xmlsoap.org/ws/2002/07/secext">  <soap:Header>    <wsse:Security>      <wsse:UsernameToken>        <wsse:Username>@{[ $client->username || '' ]}</wsse:Username>        <wsse:Password Type="wsse:PasswordDigest">$digest</wsse:Password>        <wsse:Nonce>$nonce_enc</wsse:Nonce>        <wsu:Created>$now</wsu:Created>      </wsse:UsernameToken>    </wsse:Security>  </soap:Header>  <soap:Body>    <$method xmlns="http://schemas.xmlsoap.org/wsdl/http/">$xml    </$method>  </soap:Body></soap:Envelope>SOAP        $req->content($xml);        $req->content_length(length $xml);        $req->header('SOAPAction', 'http://schemas.xmlsoap.org/wsdl/http/' . $method);        $req->method('POST');        $req->content_type('text/xml');    } else {        $req->header('X-WSSE', sprintf          qq(UsernameToken Username="%s", PasswordDigest="%s", Nonce="%s", Created="%s"),          $client->username || '', $digest, $nonce_enc, $now);        $req->header('Authorization', 'WSSE profile="UsernameToken"');    }}sub munge_response {    my $client = shift;    my($res) = @_;    if ($client->use_soap && (my $xml = $res->content)) {        my $doc;        if (LIBXML) {            my $parser = XML::LibXML->new;            $doc = $parser->parse_string($xml);        } else {            my $xp = XML::XPath->new(xml => $xml);            $doc = ($xp->find('/')->get_nodelist)[0];        }        my $body = first($doc, NS_SOAP, 'Body');        if (my $fault = first($body, NS_SOAP, 'Fault')) {            $res->code(textValue($fault, undef, 'faultcode'));            $res->message(textValue($fault, undef, 'faultstring'));            $res->content('');            $res->content_length(0);        } else {            $xml = join '', map $_->toString(LIBXML ? 1 : 0),                LIBXML ? $body->childNodes : $body->getChildNodes;            $res->content($xml);            $res->content_length(1);        }    }}sub make_nonce { sha1(sha1(time() . {} . rand() . $$)) }package LWP::UserAgent::AtomClient;use strict;use base qw( LWP::UserAgent );my %ClientOf;sub new {    my($class, $client) = @_;    my $ua = $class->SUPER::new;    $ClientOf{$ua} = $client;    $ua;}sub get_basic_credentials {    my($ua, $realm, $url, $proxy) = @_;    my $client = $ClientOf{$ua} or die "Cannot find $ua";    return $client->username, $client->password;}sub DESTROY {    my $self = shift;    delete $ClientOf{$self};}package LWP::Authen::Wsse;use strict;use MIME::Base64;use Digest::SHA1;use DateTime;sub authenticate {    my($class, $ua, $proxy, $auth_param, $res, $req, $arg, $size) = @_;    my($user, $pass) = $ua->get_basic_credentials($auth_param->{realm},        $req->url, $proxy);    return $res unless defined $user && defined $pass;    my $nonce = XML::Atom::Client->make_nonce;    my $nonce_enc = MIME::Base64::encode_base64($nonce, '');    my $now = DateTime->now->iso8601 . 'Z';    my $digest = MIME::Base64::encode_base64(        Digest::SHA1::sha1($nonce . $now . ($pass || '')), ''    );    my $auth_header = $proxy ? "Proxy-Authorization" : "Authorization";    my $wsse_value = sprintf        qq(UsernameToken Username="%s", PasswordDigest="%s", Nonce="%s", Created="%s"),        $user || '', $digest, $nonce_enc, $now;    # Need to check this isn't a repeated fail!    my $r = $res;    while ($r) {        my $wsse = $r->request->header('X-WSSE');        if ($wsse && $wsse eq $wsse_value) {            # here we know this failed before            $res->header("Client-Warning" =>                "Credentials for '$user' failed before");            return $res;        }        $r = $r->previous;    }    my $referral = $req->clone;    $referral->header($auth_header, 'WSSE profile="UsernameToken"');    $referral->header('X-WSSE' => $wsse_value);    return $ua->request($referral, $arg, $size, $res);}1;__END__=head1 NAMEXML::Atom::Client - A client for the Atom API=head1 SYNOPSIS    use XML::Atom::Client;    use XML::Atom::Entry;    my $api = XML::Atom::Client->new;    $api->username('Melody');    $api->password('Nelson');    my $entry = XML::Atom::Entry->new;    $entry->title('New Post');    $entry->content('Content of my post.');    my $EditURI = $api->createEntry($PostURI, $entry);    my $feed = $api->getFeed($FeedURI);    my @entries = $feed->entries;    my $entry = $api->getEntry($EditURI);=head1 DESCRIPTIONI<XML::Atom::Client> implements a client for the Atom API described atI<http://bitworking.org/projects/atom/draft-gregorio-09.html>, with theauthentication scheme described atI<http://www.intertwingly.net/wiki/pie/DifferentlyAbledClients>.B<NOTE:> the API, and particularly the authentication scheme, are stillin flux.=head1 USAGE=head2 XML::Atom::Client->new(%param)=head2 $api->use_soap([ 0 | 1 ])I<XML::Atom::Client> supports both the REST and SOAP-wrapper versions of theAtom API. By default, the REST version of the API will be used, but you canturn on the SOAP wrapper--for example, if you need to connect to a serverthat supports only the SOAP wrapper--by calling I<use_soap> with a value ofC<1>:    $api->use_soap(1);If called without arguments, returns the current value of the flag.=head2 $api->username([ $username ])If called with an argument, sets the username for login to I<$username>.Returns the current username that will be used when logging in to theAtom server.=head2 $api->password([ $password ])If called with an argument, sets the password for login to I<$password>.Returns the current password that will be used when logging in to theAtom server.=head2 $api->createEntry($PostURI, $entry)Creates a new entry.I<$entry> must be an I<XML::Atom::Entry> object.=head2 $api->getEntry($EditURI)Retrieves the entry with the given URL I<$EditURI>.Returns an I<XML::Atom::Entry> object.=head2 $api->updateEntry($EditURI, $entry)Updates the entry at URL I<$EditURI> with the entry I<$entry>, which must bean I<XML::Atom::Entry> object.Returns true on success, false otherwise.=head2 $api->deleteEntry($EditURI)Deletes the entry at URL I<$EditURI>.=head2 $api->getFeed($FeedURI)Retrieves the feed at I<$FeedURI>.Returns an I<XML::Atom::Feed> object representing the feed returnedfrom the server.=head2 ERROR HANDLINGMethods return C<undef> on error, and the error message can be retrievedusing the I<errstr> method.=head1 AUTHOR & COPYRIGHTPlease see the I<XML::Atom> manpage for author, copyright, and licenseinformation.=cut

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
国产综合久久久久久鬼色 | 色域天天综合网| 国产精品美女久久久久aⅴ国产馆| 亚洲另类在线视频| 色综合激情久久| 久久av老司机精品网站导航| 日韩一区二区电影在线| 国产精品视频看| 国产在线视频一区二区| 久久精品无码一区二区三区| 韩国av一区二区三区四区| 久久先锋影音av鲁色资源网| 国产自产视频一区二区三区 | 亚洲一区在线看| 欧美日韩一区二区在线视频| 婷婷综合五月天| 欧美一区二区久久| 国产经典欧美精品| 亚洲人成亚洲人成在线观看图片| 色婷婷久久综合| 国内外成人在线| 亚洲视频中文字幕| 欧美日韩午夜影院| 韩国中文字幕2020精品| 中文字幕久久午夜不卡| 91视视频在线观看入口直接观看www| 综合网在线视频| 在线中文字幕一区| 蜜臀久久99精品久久久久宅男| 国产欧美视频在线观看| 日本道色综合久久| 国内精品自线一区二区三区视频| 中文字幕一区二区三区不卡| 欧美丰满高潮xxxx喷水动漫| 不卡高清视频专区| 久久精品国产亚洲高清剧情介绍| 国产精品嫩草影院av蜜臀| 51精品秘密在线观看| 不卡在线视频中文字幕| 免费人成精品欧美精品| 亚洲色图一区二区三区| 久久久精品欧美丰满| 欧美日韩成人在线| 色噜噜久久综合| 成人一区二区三区| 成人性生交大合| 亚洲一区二区三区视频在线播放 | 午夜不卡av免费| 国产亚洲精品7777| 91啦中文在线观看| 美日韩黄色大片| 日本v片在线高清不卡在线观看| 日本一区二区高清| 国产精品久久久久aaaa樱花| 久久久久88色偷偷免费| 国产亚洲精品aa午夜观看| 欧美国产国产综合| 中文字幕一区二区三区不卡在线| 国产精品欧美久久久久一区二区| 欧美精品一区二区高清在线观看| 欧美不卡一二三| 国产农村妇女毛片精品久久麻豆 | 国产亚洲欧美色| 中文字幕亚洲一区二区av在线| 国产精品久久久久一区二区三区| 国产精品免费av| 亚洲黄色录像片| 麻豆精品视频在线| 国产不卡视频一区二区三区| 国产成人av在线影院| 99视频超级精品| 欧美一区二区观看视频| 国产亚洲一本大道中文在线| 亚洲色图一区二区| 麻豆91精品91久久久的内涵| 国产suv一区二区三区88区| 精品国产乱子伦一区| 国产精品国产三级国产三级人妇| 首页欧美精品中文字幕| www.色综合.com| 日韩精品自拍偷拍| 亚洲欧美日本在线| 国产精品主播直播| 欧美色手机在线观看| 国产精品久久网站| 激情欧美一区二区三区在线观看| 91色视频在线| 国产精品国产三级国产专播品爱网| 午夜影院久久久| jlzzjlzz亚洲日本少妇| 久久蜜桃av一区精品变态类天堂 | 一区二区三区日韩欧美精品| 国产一区在线观看视频| 91精品国产色综合久久不卡蜜臀| 中文字幕制服丝袜一区二区三区 | 亚洲视频电影在线| 成人福利视频在线看| 久久在线免费观看| 国产另类ts人妖一区二区| 日韩欧美久久久| 久久精品国产澳门| 精品国产自在久精品国产| 视频一区欧美精品| 91精品国产91久久久久久一区二区 | 欧美大度的电影原声| 美女网站视频久久| 国产日韩综合av| 播五月开心婷婷综合| 中文字幕在线不卡一区二区三区 | 日韩av成人高清| 精品av综合导航| 波多野结衣91| 亚洲国产视频一区二区| 欧美一区二区观看视频| 国产精选一区二区三区| 亚洲美女偷拍久久| 91麻豆精品国产91久久久久久| 免费一级欧美片在线观看| 久久美女高清视频| 色综合一区二区| 久久激情综合网| 国产精品久久毛片a| 在线精品观看国产| 国产欧美精品国产国产专区 | 三级欧美韩日大片在线看| 久久婷婷色综合| 93久久精品日日躁夜夜躁欧美| 日韩一区在线看| 久久不见久久见中文字幕免费| 久久久久久久精| 欧美精品视频www在线观看| 高清在线不卡av| 精品亚洲国产成人av制服丝袜| 综合激情成人伊人| xnxx国产精品| 欧美老肥妇做.爰bbww| 成人黄色大片在线观看| 精品中文字幕一区二区| 一区二区三区产品免费精品久久75| 久久久久久综合| 日韩欧美视频在线| 555夜色666亚洲国产免| 色乱码一区二区三区88| 成人福利在线看| 粉嫩av一区二区三区粉嫩| 久久成人久久爱| 另类中文字幕网| 久久国产精品一区二区| 日韩国产精品91| 午夜av一区二区| 亚洲电影激情视频网站| 亚洲电影你懂得| 日韩激情视频网站| 另类小说色综合网站| 美女被吸乳得到大胸91| 国产又粗又猛又爽又黄91精品| 国产综合色视频| eeuss鲁一区二区三区| 99re热视频这里只精品| 欧美视频一二三区| 色婷婷综合视频在线观看| 欧美无人高清视频在线观看| 欧美美女激情18p| 欧美国产精品一区| 亚洲男同1069视频| 视频在线观看国产精品| 激情深爱一区二区| 一本到不卡免费一区二区| 8v天堂国产在线一区二区| 久久综合九色综合久久久精品综合| 国产性色一区二区| 亚洲在线视频免费观看| 精品一区二区三区视频| 色婷婷综合在线| 精品电影一区二区| 亚洲国产欧美一区二区三区丁香婷| 国产在线乱码一区二区三区| 91极品视觉盛宴| 久久久久久**毛片大全| 亚洲18影院在线观看| av一本久道久久综合久久鬼色| 欧美精品久久久久久久多人混战 | 成人精品国产福利| 亚洲精品在线电影| 日韩av中文字幕一区二区三区| 成人免费毛片高清视频| 日韩一区二区三| 五月婷婷综合在线| 在线免费观看视频一区| 久久综合久久久久88| 日本亚洲最大的色成网站www| 一本到不卡精品视频在线观看| 国产精品乱码一区二三区小蝌蚪| 免费在线观看一区| 在线综合亚洲欧美在线视频| 亚洲一区二区三区视频在线| 欧美在线观看视频一区二区| 国产精品欧美一区喷水| 国产成人午夜高潮毛片| 国产网站一区二区|