view release on metacpan or search on metacpan
lib/Coro/Twiggy.pm view on Meta::CPAN
use 5.008008;
use strict;
use warnings;
use Twiggy::Server;
use Scalar::Util 'weaken';
use Coro;
use Data::Dumper;
our $VERSION = '0.03';
lib/Coro/Twiggy.pm view on Meta::CPAN
$self->{app} = $cb || DEFAULT_SERVICE;
}
sub _app {
my ($self) = @_;
weaken $self;
sub {
my ($env) = @_;
sub {
my ($cb) = @_;
async {
view all matches for this distribution
view release on metacpan or search on metacpan
lib/Couch/DB/Client.pm view on Meta::CPAN
use Couch::DB::Util qw(flat);
use Couch::DB::Result ();
use Log::Report 'couch-db';
use Scalar::Util qw(weaken blessed);
use List::Util qw(first);
use MIME::Base64 qw(encode_base64);
use Storable qw(dclone);
use URI::Escape qw(uri_escape);
lib/Couch/DB/Client.pm view on Meta::CPAN
$self->{CDC_name} = delete $args->{name} || "$server";
$self->{CDC_ua} = delete $args->{user_agent} or panic "Requires 'user_agent'";
$self->{CDC_uuids} = [];
$self->{CDC_couch} = delete $args->{couch} or panic "Requires 'couch'";
weaken $self->{CDC_couch};
$self->{CDC_hdrs} = my $headers = delete $args->{headers} || {};
my $username = delete $args->{username} // '';
$self->login(
view all matches for this distribution
view release on metacpan or search on metacpan
async->refcount = 1;
async->iops_ptr = cbcio;
cbcio->v.v0.cookie = async;
async->selfrv = newRV_inc(ptriv); sv_rvweaken(async->selfrv);
async->action_sv = newSViv(0); SvREADONLY_on(async->action_sv);
async->flags_sv = newSViv(0); SvREADONLY_on(async->flags_sv);
async->usec_sv = newSVnv(0); SvREADONLY_on(async->usec_sv);
async->sched_r_sv = newSViv(0); SvREADONLY_on(async->sched_r_sv);
async->sched_w_sv = newSViv(0); SvREADONLY_on(async->sched_w_sv);
view all matches for this distribution
view release on metacpan or search on metacpan
=head2 Recursive specifications
=over 4
=item json_type_weaken
This function can be used as an argument for L</json_type_arrayof>,
L</json_type_hashof> or L</json_type_anyof> functions to create weak
references suitable for complicated recursive structures. It depends
on L<the weaken function from Scalar::Util|Scalar::Util/weaken> module.
See following example:
my $struct = {
type => JSON_TYPE_STRING,
array => json_type_arrayof(JSON_TYPE_INT),
};
$struct->{recursive} = json_type_anyof(
json_type_weaken($struct),
json_type_arrayof(JSON_TYPE_STRING),
);
If you want to encode all perl scalars to JSON string types despite
how complicated is input perl structure you can define JSON type
specification for alternatives recursively. It could be defined as:
my $type = json_type_anyof();
$type->[0] = JSON_TYPE_STRING_OR_NULL;
$type->[1] = json_type_arrayof(json_type_weaken($type));
$type->[2] = json_type_hashof(json_type_weaken($type));
print encode_json([ 10, "10", { key => 10 } ], $type);
# ["10","10",{"key":"10"}]
An alternative solution for encoding all scalars to JSON strings is to
use strict;
use warnings;
BEGIN {
if (eval { require Scalar::Util }) {
Scalar::Util->import('weaken');
} else {
*weaken = sub($) { die 'Scalar::Util is required for weaken' };
}
}
# This exports needed XS constants to perl
use Cpanel::JSON::XS ();
our @EXPORT = our @EXPORT_OK = qw(
json_type_arrayof
json_type_hashof
json_type_anyof
json_type_null_or_anyof
json_type_weaken
JSON_TYPE_NULL
JSON_TYPE_BOOL
JSON_TYPE_INT
JSON_TYPE_FLOAT
JSON_TYPE_STRING
use constant JSON_TYPE_WEAKEN_CLASS => 'Cpanel::JSON::XS::Type::Weaken';
sub json_type_anyof {
my ($scalar, $array, $hash);
my ($scalar_weaken, $array_weaken, $hash_weaken);
foreach (@_) {
my $type = $_;
my $ref = ref($_);
my $weaken;
if ($ref eq JSON_TYPE_WEAKEN_CLASS) {
$type = ${$type};
$ref = ref($type);
$weaken = 1;
}
if ($ref eq '') {
die 'Only one scalar type can be specified in anyof' if defined $scalar;
$scalar = $type;
$scalar_weaken = $weaken;
} elsif ($ref eq 'ARRAY' or $ref eq JSON_TYPE_ARRAYOF_CLASS) {
die 'Only one array type can be specified in anyof' if defined $array;
$array = $type;
$array_weaken = $weaken;
} elsif ($ref eq 'HASH' or $ref eq JSON_TYPE_HASHOF_CLASS) {
die 'Only one hash type can be specified in anyof' if defined $hash;
$hash = $type;
$hash_weaken = $weaken;
} else {
die 'Only scalar, array or hash can be specified in anyof';
}
}
my $type = [$scalar, $array, $hash];
weaken $type->[0] if $scalar_weaken;
weaken $type->[1] if $array_weaken;
weaken $type->[2] if $hash_weaken;
return bless $type, JSON_TYPE_ANYOF_CLASS;
}
sub json_type_null_or_anyof {
foreach (@_) {
sub json_type_arrayof {
die 'Exactly one type must be specified in arrayof' if scalar @_ != 1;
my $type = $_[0];
if (ref($type) eq JSON_TYPE_WEAKEN_CLASS) {
$type = ${$type};
weaken $type;
}
return bless \$type, JSON_TYPE_ARRAYOF_CLASS;
}
sub json_type_hashof {
die 'Exactly one type must be specified in hashof' if scalar @_ != 1;
my $type = $_[0];
if (ref($type) eq JSON_TYPE_WEAKEN_CLASS) {
$type = ${$type};
weaken $type;
}
return bless \$type, JSON_TYPE_HASHOF_CLASS;
}
sub json_type_weaken {
die 'Exactly one type must be specified in weaken' if scalar @_ != 1;
die 'Scalar cannot be specfied in weaken' if ref($_[0]) eq '';
return bless \(my $type = $_[0]), JSON_TYPE_WEAKEN_CLASS;
}
1;
view all matches for this distribution
view release on metacpan or search on metacpan
sv_reftype|||
sv_release_COW|||
sv_replace|||
sv_report_used|||
sv_reset|||
sv_rvweaken||5.006000|
sv_setiv_mg|5.004050||p
sv_setiv|||
sv_setnv_mg|5.006000||p
sv_setnv|||
sv_setpv_mg|5.004050||p
view all matches for this distribution
view release on metacpan or search on metacpan
sv_release_COW|||
sv_release_IVX|||
sv_replace|||
sv_report_used|||
sv_reset|||
sv_rvweaken||5.006000|
sv_setiv_mg|5.006000||p
sv_setiv|||
sv_setnv_mg|5.006000||p
sv_setnv|||
sv_setpv_mg|5.006000||p
view all matches for this distribution
view release on metacpan or search on metacpan
script/diceware_modhex_wordlist.pl view on Meta::CPAN
using the list only handles the words. Default the rolls are included.
=item * --min
The minimum length of the words selected for the list. Short words in a list
could weaken a passphrase when a combination of short words lead to a short
passphrase that can be cracked more easily than the used entropy of the Diceware
method to generate the passphrase suggests. Default 5.
=item * --max
script/diceware_modhex_wordlist.pl view on Meta::CPAN
Because the ModHex requirement already limits the number of allowed words
significantly it usually isn't possible to limit the list further to words that
aren't composites of each other and still get a list of 7776 words as a result.
Therefore the words in these wordlists require the use of spaces between the
words in a passphrase to avoid weakening the passphrase.
=head1 AUTHOR
Roland van Ipenburg <roland@rolandvanipenburg.com>
view all matches for this distribution
view release on metacpan or search on metacpan
script/diceware_modhex_wordlist.pl view on Meta::CPAN
using the list only handles the words. Default the rolls are included.
=item * --min
The minimum length of the words selected for the list. Short words in a list
could weaken a passphrase when a combination of short words lead to a short
passphrase that can be cracked more easily than the used entropy of the Diceware
method to generate the passphrase suggests. Default 5.
=item * --max
script/diceware_modhex_wordlist.pl view on Meta::CPAN
Because the ModHex requirement already limits the number of allowed words
significantly it usually isn't possible to limit the list further to words that
aren't composites of each other and still get a list of 7776 words as a result.
Therefore the words in these wordlists require the use of spaces between the
words in a passphrase to avoid weakening the passphrase.
=head1 AUTHOR
Roland van Ipenburg <roland@rolandvanipenburg.com>
view all matches for this distribution
view release on metacpan or search on metacpan
lib/Crypt/Diceware/Wordlist/Common.pm view on Meta::CPAN
vulgarity wacko wad wadded wading wads wage waif waistcoat waistline waiter
waiting waive wake waked walkable walker walkers walking walled wallop
wallow waltz wampum wane waned wanes wangled wannabe wanted wanting ward
warden warehouse warhead warheads warily wariness warlike warmed
warning warp warpath warrior wary wash washtub waste wasteful watchful
waterline wavelet waxy way weakens weakest weakling weal wean wear wearied
wearisome webcams website wed wee weedy weekly weepers weigh weirdest
weirdly welcome well welt west westward whatnot wheel wheeze whereupon
wherever wherewith whet while whiled whimper whimsical whine whip whipping
whippy whirr whirred whistle white whittle whiz whodunit wholly whomever
whoop whoops whooshes wide widening widowed widower wield wielders
view all matches for this distribution
view release on metacpan or search on metacpan
sv_release_COW|||
sv_release_IVX|||
sv_replace|||
sv_report_used|||
sv_reset|||
sv_rvweaken||5.006000|
sv_setiv_mg|5.006000||p
sv_setiv|||
sv_setnv_mg|5.006000||p
sv_setnv|||
sv_setpv_mg|5.006000||p
view all matches for this distribution
view release on metacpan or search on metacpan
perl_glue/ppport.h view on Meta::CPAN
sv_release_COW|||
sv_release_IVX|||
sv_replace|||
sv_report_used|||
sv_reset|||
sv_rvweaken||5.006000|
sv_setiv_mg|5.004050||p
sv_setiv|||
sv_setnv_mg|5.006000||p
sv_setnv|||
sv_setpv_mg|5.004050||p
view all matches for this distribution
view release on metacpan or search on metacpan
lib/Crypt/ppport.h view on Meta::CPAN
SvROK_off|5.003007|5.003007|
SvROK_on|5.003007|5.003007|
SvRV|5.003007|5.003007|
SvRV_const|5.010001||Viu
SvRV_set|5.009003|5.003007|p
sv_rvunweaken|5.027004|5.027004|
sv_rvweaken|5.006000|5.006000|
SvRVx|5.003007||Viu
SvRX|5.009005|5.003007|p
SvRXOK|5.009005|5.003007|p
SV_SAVED_COPY|5.009005||Viu
SvSCREAM|5.003007||Viu
view all matches for this distribution
view release on metacpan or search on metacpan
lib/Crypt/IDA.pm view on Meta::CPAN
compatibility with any code implemented using the current semantics.
=item * Offer the choice of padding input with random padding rather
than null padding. While it's beyond the scope of this document to
present an analysis of the algorithm from a cryptographic standpoint,
it may be possible that padding with predictable zero bytes may weaken
the security of this implementation. Padding with random data should
remove that potential weakness.
=item * Force or give the option of always using the highest-quality
RNG available (see L<KNOWN BUGS>).
view all matches for this distribution
view release on metacpan or search on metacpan
sv_release_COW|||
sv_release_IVX|||
sv_replace|||
sv_report_used|||
sv_reset|||
sv_rvweaken||5.006000|
sv_setiv_mg|5.006000||p
sv_setiv|||
sv_setnv_mg|5.006000||p
sv_setnv|||
sv_setpv_mg|5.006000||p
view all matches for this distribution
view release on metacpan or search on metacpan
sv_reftype|||
sv_release_COW|||
sv_replace|||
sv_report_used|||
sv_reset|||
sv_rvweaken||5.006000|
sv_setiv_mg|5.004050||p
sv_setiv|||
sv_setnv_mg|5.006000||p
sv_setnv|||
sv_setpv_mg|5.004050||p
view all matches for this distribution
view release on metacpan or search on metacpan
sv_ref||5.015004|
sv_replace|||
sv_report_used|||
sv_resetpvn|||
sv_reset|||
sv_rvweaken||5.006000|
sv_sethek|||
sv_setiv_mg|5.004050||p
sv_setiv|||
sv_setnv_mg|5.006000||p
sv_setnv|||
view all matches for this distribution
view release on metacpan or search on metacpan
sv_reftype|||
sv_release_COW|||
sv_replace|||
sv_report_used|||
sv_reset|||
sv_rvweaken||5.006000|
sv_setiv_mg|5.004050||p
sv_setiv|||
sv_setnv_mg|5.006000||p
sv_setnv|||
sv_setpv_mg|5.004050||p
view all matches for this distribution
view release on metacpan or search on metacpan
sv_release_COW|||
sv_replace|||
sv_report_used|||
sv_resetpvn|||
sv_reset|||
sv_rvweaken||5.006000|
sv_sethek|||
sv_setiv_mg|5.004050||p
sv_setiv|||
sv_setnv_mg|5.006000||p
sv_setnv|||
view all matches for this distribution
view release on metacpan or search on metacpan
SvROK_off|5.003007|5.003007|
SvROK_on|5.003007|5.003007|
SvRV|5.003007|5.003007|
SvRV_const|5.010001||Viu
SvRV_set|5.009003|5.003007|p
sv_rvunweaken|5.027004|5.027004|
sv_rvweaken|5.006000|5.006000|
SvRVx|5.003007||Viu
SvRX|5.009005|5.003007|p
SvRXOK|5.009005|5.003007|p
SV_SAVED_COPY|5.009005||Viu
SvSCREAM|5.003007||Viu
view all matches for this distribution
view release on metacpan or search on metacpan
sv_reftype|||
sv_release_COW|||
sv_replace|||
sv_report_used|||
sv_reset|||
sv_rvweaken||5.006000|
sv_setiv_mg|5.004050||p
sv_setiv|||
sv_setnv_mg|5.006000||p
sv_setnv|||
sv_setpv_mg|5.004050||p
view all matches for this distribution
view release on metacpan or search on metacpan
sv_reftype|||
sv_release_COW|||
sv_replace|||
sv_report_used|||
sv_reset|||
sv_rvweaken||5.006000|
sv_setiv_mg|5.004050||p
sv_setiv|||
sv_setnv_mg|5.006000||p
sv_setnv|||
sv_setpv_mg|5.004050||p
view all matches for this distribution
view release on metacpan or search on metacpan
generation.
I identified the algorithm for login key generation to be MD5.
Chen Peng reverse-engineered the rest of assembly codes created by FreeOICQ and
identified the core cipher used by OICQ to be a weakened version of TEA, Tiny
Encryption Algorithm.
TEA was invented by David Wheeler and Roger Needham at Cambridge University.
They recommend using 32 rounds. OICQ only uses 16 rounds.
view all matches for this distribution
view release on metacpan or search on metacpan
sv_reftype|||
sv_release_COW|||
sv_replace|||
sv_report_used|||
sv_reset|||
sv_rvweaken||5.006000|
sv_setiv_mg|5.004050||p
sv_setiv|||
sv_setnv_mg|5.006000||p
sv_setnv|||
sv_setpv_mg|5.004050||p
view all matches for this distribution
view release on metacpan or search on metacpan
sv_reftype|||
sv_release_COW|||
sv_replace|||
sv_report_used|||
sv_reset|||
sv_rvweaken||5.006000|
sv_setiv_mg|5.004050||p
sv_setiv|||
sv_setnv_mg|5.006000||p
sv_setnv|||
sv_setpv_mg|5.004050||p
view all matches for this distribution
view release on metacpan or search on metacpan
sv_reftype|||
sv_release_COW|||
sv_replace|||
sv_report_used|||
sv_reset|||
sv_rvweaken||5.006000|
sv_setiv_mg|5.004050||p
sv_setiv|||
sv_setnv_mg|5.006000||p
sv_setnv|||
sv_setpv_mg|5.004050||p
view all matches for this distribution
view release on metacpan or search on metacpan
SvROK_off|5.003007|5.003007|
SvROK_on|5.003007|5.003007|
SvRV|5.003007|5.003007|
SvRV_const|5.010001||Viu
SvRV_set|5.009003|5.003007|p
sv_rvunweaken|5.027004|5.027004|
sv_rvweaken|5.006000|5.006000|
SvRVx|5.003007||Viu
SvRX|5.009005|5.003007|p
SvRXOK|5.009005|5.003007|p
SV_SAVED_COPY|5.009005||Viu
SvSCREAM|5.003007||Viu
view all matches for this distribution
view release on metacpan or search on metacpan
sv_reftype|||
sv_release_COW|||
sv_replace|||
sv_report_used|||
sv_reset|||
sv_rvweaken||5.006000|
sv_setiv_mg|5.004050||p
sv_setiv|||
sv_setnv_mg|5.006000||p
sv_setnv|||
sv_setpv_mg|5.004050||p
view all matches for this distribution
view release on metacpan or search on metacpan
sv_reftype|||
sv_release_COW|||
sv_replace|||
sv_report_used|||
sv_reset|||
sv_rvweaken||5.006000|
sv_setiv_mg|5.004050||p
sv_setiv|||
sv_setnv_mg|5.006000||p
sv_setnv|||
sv_setpv_mg|5.004050||p
view all matches for this distribution
view release on metacpan or search on metacpan
SvROK_off|5.003007|5.003007|
SvROK_on|5.003007|5.003007|
SvRV|5.003007|5.003007|
SvRV_const|5.010001||Viu
SvRV_set|5.009003|5.003007|p
sv_rvunweaken|5.027004|5.027004|
sv_rvweaken|5.006000|5.006000|
SvRVx|5.003007||Viu
SvRX|5.009005|5.003007|p
SvRXOK|5.009005|5.003007|p
SV_SAVED_COPY|5.009005||Viu
SvSCREAM|5.003007||Viu
view all matches for this distribution
view release on metacpan or search on metacpan
SvROK_off|5.003007|5.003007|
SvROK_on|5.003007|5.003007|
SvRV|5.003007|5.003007|
SvRV_const|5.010001||Viu
SvRV_set|5.009003|5.003007|p
sv_rvunweaken|5.027004|5.027004|
sv_rvweaken|5.006000|5.006000|
SvRVx|5.003007||Viu
SvRX|5.009005|5.003007|p
SvRXOK|5.009005|5.003007|p
SV_SAVED_COPY|5.009005||Viu
SvSCREAM|5.003007||Viu
view all matches for this distribution