my $csr = Net::OpenID::Consumer->new(
ua => LWP::UserAgent->new,
consumer_secret => '123456xXx',
required_root => "http://www.myopenidsample.net/",
);
my $openid = "https://me.yahoo.com";
my $claimed_id = $csr->claimed_identity($openid);
if ($claimed_id){
my $check_url = $claimed_id->check_url(
delayed_return => 1,
return_to => "http://www.myopenidsample.net/response.cgi",
trust_root => "http://www.myopenidsample.net/",
);
print $q->redirect($check_url);
}
如何获取电子邮件、名字、姓氏和国家/地区等属性?如何将以下参数附加到 URL?
openid.ext1.mode fetch_request openid.ext1. 必需的国家、电子邮件、名字、姓氏、语言 openid.ext1.type.country http://axschema.org/contact/country/home openid.ext1.type.email http://axschema.org/contact/email openid.ext1.type.firstname http://axschema.org/namePerson/first openid.ext1.type.language http://axschema.org/pref/language openid.ext1.type.lastname http://axschema.org/namePerson/ openid.ns.ext1 http://openid.net/srv/ax/1.0