Re:Net::OpenID::Consumer::Lite ãæ¸ãã¦ã¿ã
id:tokuhirom ã® http://d.hatena.ne.jp/tokuhirom/20081129/1227923235 ã®ä»¶ãå ã® Lite ãã趣æ¨ã¨ããèæ ®ã«å ¥ããä¸ã§ã®è©±ã ãã©åãè¯ãã¨æãã¾ããã
è¿½è¨ (2008-12-01T12:51:35+09:00)
Net::OpenID::Consumer::Lite ã®ä»¶ã§ããã©ãéå®çãªæ段ããæä¾ãã¦ããªãã¨è¨ãç¹ã«æ³¨æã¯æãã¹ãã§ãã
ãã¼ã£ã¨æ£ããè¨ãã¨ã
OP Identifier ã®ã¿å¯¾å¿ãã¤ã¾ã User-Supplied Identifier ãããªã- OP Endpoint URL ã¯æ¢ç¥ã§ããå¿ è¦ããããã¤ã¾ã discovery ã¯ããªã *1
- SSL ãªã³ãªã¼
- ç½²åæ¤è¨¼ã®çºã® association ããµãã¼ãããªã
- XRI ããµãã¼ãããªã
ããªãã¾ã ããããã§ããããªã®ã§ OpenID 2.0 only ã¯æ¶ãã¹ãããªã
IRC ã«ã¦ id:miyagawa ããããã
- identification ã¨ãã¦ã® OpenID ã軽è¦å¾åã«ããï¼(èªè¨¼ç®çã®ã¿ã®ä½¿ããæ¹ãå¢ãã¦ãã)
- ã§ãauthentication ã«ä½¿ããã°ãããããã«ã¹ããã¯ã§å¯¾å¿ããªãã¦ããã
ã¿ãããªæµããåºæ¥ã¦ãã®ã¯ã©ããçãªè¶£æ¨ã®çªã£è¾¼ã¿ããããåãåæã§ããã®ã§è¨è足ãããã¨æã£ã¦è¿½è¨ãã¦ã¿ã¾ããã
ä»åã® Net::OpenID::Consumer::Lite ã«éã£ã¦ã¯æã«ãã·ã³ãã«ãª CGI ã¨ãã¦æ°è»½ã«ä½¿ããèªè¨¼ã®æ çµã¿ã¨ãã¦æä½éã®å®è£ ã¨è¨ããã¨ãæ ¹åºã«ããã®ã§ããã®è¶£æ¨ã§ã®ãç´ æ´ããããã¨è¨ãæå³ã§ãç¶ãã¹ããµã¼ãã¹ãæä¾ããéã«ã¯ããããªãã«èããªããã°ãããªããã¨ããããã ã¨è¨ããã¨ãèæ ®ã®ä¸ã§ã以ä¸ã®æç« ã«ç¶ãã¾ãã
追è¨2 (2008-12-01T14:29:09+09:00)
ãã¨"è¯ã OP"ã£ã¦ãã¬ã¼ãºãã£ããã©ã
- SSL使ã£ã¦ã¦
- OP Identifier 使ã£ã¦ã¦
- èªç¥åº¦ãé«ã
ã£ã¦ã®ãããã§ã¯æã«è¯ãç©ã ã¨è¨ãåæãããããã§ãã
(追è¨çµãã)
SSL ã«å¯¾å¿ãã¦ãªãèªè¨¼ãµã¼ããªãã¦ãã¤ãããªãæ¹ããã
ãã®éããã ãã Crypt::DH ã¨ãå¤ããã£ã¦ã®ã¯å¦¥å½ãªå¤æã
OpenID 2.0 åæã§
æ£ããè¨ããªã OP Identifier ã®ã¿ã§ã£ã¦äºã§ããããOP ã®ç¾ç¶èããããããã§ååã ã¨æãã¾ããã
check_authentication åæã§
ã¾ãã©ãã mixi ããããªããããå¾ãªãã®ã§w
XRDS ã® detect ã¨ãç¡é§ãããªã?
æåãããã¯ã©ãããªã¨æã£ããã ãã©ã
è¯è³ªãª OpenID ã®èªè¨¼ãµã¼ãã ãã対象ã«ããã軽é㪠OpenID ã®ã¯ã©ã¤ã¢ã³ãã©ã¤ãã©ãªãæ¸ãã¦ã¿ãã
ãªãã§ããªãã»ã©ããã決ãæã¡ã§ãæ§ããªãã®ãã¼ã¨å¦ã«ç´å¾ããã
ç¾æç¹ã§çµæçã«ãã¯ã¤ããªã¹ãã«ãªã£ã¡ãã£ã¦ããããããã ã«è¦ä»¶ãæºããã¨è¨ã観ç¹ããè¦ã¦ãç´ æ´ãããã¨æãã¾ããã
ã³ã¼ãã®è©±
checkid_immediate ã決ãæã¡ã«ãªã£ã¦ãã®ãã¡ãã£ã¨å«ããããã®é¨åãé¸æåºæ¥ãããããªã¼ã¨æãã¾ããã
sub check_url { my ($class, $server_url, $return_to, $extensions) = (shift, shift, shift, shift); Carp::croak("missing params") unless $return_to; Carp::croak("this module supports only https: $server_url") unless $server_url =~ /^https/; my $url = URI->new($server_url); my %args = ( 'openid.mode' => 'checkid_immediate', 'openid.return_to' => $return_to, );
ãã®è¾ºãã®è©±ãã
ã¨è¨ãã®ãåã®å ´åã¯ã»ã¨ãã©ã®ã±ã¼ã¹ã§æä¹ çã«ãã°ã¤ã³ããè¨å®ã«ããªãã®ã§ããªãã ãã©å¤ãã®å ´åã¯ããããã¦ã¼ã¹ã±ã¼ã¹ã®ãå¤ãã®ããªãã
ã ãããã£ã±ãåé¡ã«ãªããªãããã
ã¨è¨ã訳ã§ç¹ã«çªã£è¾¼ã¿ã©ãããç¡ãã£ãã¨è¨ãã®ãã¾ã¨ãã§ããã
*1:ããã£ã¦ XRDS ã ããããªã㦠HTML based discovery ãã±ã¢ãã¦ãªãã®ã§ discovery ããµãã¼ããã¦ãªããæ£ããããº