diff options
author | skv <skv@FreeBSD.org> | 2008-06-11 20:29:54 +0800 |
---|---|---|
committer | skv <skv@FreeBSD.org> | 2008-06-11 20:29:54 +0800 |
commit | c3a712a4f79324943d10a4fafa6c45adb130719e (patch) | |
tree | 428f78dc7ba866d3fe60883707daaa747552d33f /net | |
parent | dc396bd8a66a61ffa7d04cca883d735f488301a6 (diff) | |
download | freebsd-ports-gnome-c3a712a4f79324943d10a4fafa6c45adb130719e.tar.gz freebsd-ports-gnome-c3a712a4f79324943d10a4fafa6c45adb130719e.tar.zst freebsd-ports-gnome-c3a712a4f79324943d10a4fafa6c45adb130719e.zip |
Fixes:
1. Support multivalue rel in <link> (e.g. <link rel="openid2.server openid.server">
2. Support numbers as keys in hmac.
3. Silence a warning.
PR: ports/124272
Submitted by: Alex Kapranoff <kappa xx rambler-co.ru>
Diffstat (limited to 'net')
-rw-r--r-- | net/p5-Net-OpenID-Consumer/Makefile | 4 | ||||
-rw-r--r-- | net/p5-Net-OpenID-Consumer/files/patch-Consumer.pm | 29 |
2 files changed, 33 insertions, 0 deletions
diff --git a/net/p5-Net-OpenID-Consumer/Makefile b/net/p5-Net-OpenID-Consumer/Makefile index d652117745af..d9a6ced35bbc 100644 --- a/net/p5-Net-OpenID-Consumer/Makefile +++ b/net/p5-Net-OpenID-Consumer/Makefile @@ -7,6 +7,7 @@ PORTNAME= Net-OpenID-Consumer PORTVERSION= 0.14 +PORTREVISION= 1 CATEGORIES= net security perl5 MASTER_SITES= CPAN MASTER_SITE_SUBDIR= Net @@ -27,4 +28,7 @@ PERL_CONFIGURE= yes MAN3= Net::OpenID::Association.3 Net::OpenID::ClaimedIdentity.3 \ Net::OpenID::Consumer.3 Net::OpenID::VerifiedIdentity.3 +post-patch: + @${FIND} ${WRKSRC} -type f -name "*.orig" -delete + .include <bsd.port.mk> diff --git a/net/p5-Net-OpenID-Consumer/files/patch-Consumer.pm b/net/p5-Net-OpenID-Consumer/files/patch-Consumer.pm new file mode 100644 index 000000000000..cdd5ab0a05f8 --- /dev/null +++ b/net/p5-Net-OpenID-Consumer/files/patch-Consumer.pm @@ -0,0 +1,29 @@ +--- Consumer.pm 2007-08-04 02:38:53.000000000 +0400 ++++ lib/Net/OpenID/Consumer.pm 2008-06-04 19:10:37.000000000 +0400 +@@ -235,7 +235,7 @@ + # OpenID servers / delegated identities + # <link rel="openid.server" href="http://www.livejournal.com/misc/openid.bml" /> + if ($type eq "link" && +- $val =~ /\brel=.openid\.(server|delegate)./i && ($temp = $1) && ++ $val =~ /\brel=[\"\'][^\"\']*\bopenid\.(server|delegate)\b/i && ($temp = $1) && + $val =~ m!\bhref=[\"\']([^\"\']+)[\"\']!i) { + $ret->{"openid.$temp"} = $1; + next; +@@ -301,7 +301,8 @@ + $ret->{$k} =~ s/&(\w+);/$emap->{$1} || ""/eg; + } + +- $self->_debug("semantic info ($url) = " . join(", ", %$ret)); ++ $self->_debug("semantic info ($url) = " . join(", ", ++ map { defined($ret->{$_}) ? ($_ => $ret->{$_}) : () } keys %$ret)); + + return $ret; + } +@@ -543,6 +544,7 @@ + sub hmac { + my($data, $key, $hash_func, $block_size) = @_; + $block_size ||= 64; ++ $key = $key . ''; # stringify for charwise ^ to work + $key = &$hash_func($key) if length($key) > $block_size; + + my $k_ipad = $key ^ (chr(0x36) x $block_size); |