HTTP::...::Basic(3pm)
β¨ HTTP::...::Basic β¨
okay so bestie, this page is from the User Contributed Perl Documentation and it's all about HTTP::Headers::ActionPack::Authorization::Basic β the Basic Authorization Header. that's the manual name, that's the vibe, we move π
π NAME π
HTTP::Headers::ActionPack::Authorization::Basic β The Basic Authorization Header β¨
πΈ VERSION πΈ
version 0.09 π«Ά
π¦ SYNOPSIS π¦
okay so here's the whole mood board, literally copy-paste:
use HTTP::Headers::ActionPack::Authorization::Basic;
# create from string
my $auth = HTTP::Headers::ActionPack::Authorization::Basic->new_from_string(
'Basic QWxhZGRpbjpvcGVuIHNlc2FtZQ=='
);
# create from parameters
my $auth = HTTP::Headers::ActionPack::Authorization::Basic->new(
'Basic' => {
username => 'Aladdin',
password => 'open sesame'
}
);
my $auth = HTTP::Headers::ActionPack::Authorization::Basic->new(
'Basic' => [ 'Aladdin', 'open sesame' ]
);
my $auth = HTTP::Headers::ActionPack::Authorization::Basic->new(
'Basic' => 'QWxhZGRpbjpvcGVuIHNlc2FtZQ=='
);
the way there are four different ways to build the same thing?? that's not a red flag that's a green flag actually π
π DESCRIPTION π
so this class represents the Authorization header, but likeβ¦ hyperfixated on the 'Basic' type specifically. main character energy, one header type only, we stan a specialist π
π METHODS π
π
new ( $type, $credentials )
okay so the $credentials argument is giving choose your own adventure, and it can be any one of these three:
- a Base64 encoded string β literally the thing you'd get passed in via the header
- a HASH ref with
usernameandpasswordkeys - a two element ARRAY ref where the first element is the
usernameand the second is thepassword
pick your fighter, they all work π«Ά
β¨ and then the rest β¨
these are the other methods, listed here exactly as the docs list them, no commentary attached β so ngl I'm not about to make stuff up about them π
new_from_string ( $header_string )auth_typeusernamepasswordas_string
π AUTHOR π
Stevan Little <stevan.little@iinteractive.com> β icon, legend, the moment π
π«Ά CONTRIBUTORS π«Ά
- Andrew Nelson <anelson@cpan.org>
- Dave Rolsky <autarch@urth.org>
- Florian Ragwitz <rafl@debian.org>
- Jesse Luehrs <doy@tozt.net>
- Karen Etheridge <ether@cpan.org>
the group chat came THROUGH, fr fr π
β COPYRIGHT AND LICENSE β
This software is copyright (c) 2012 by Infinity Interactive, Inc..
This is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself. slay, free software rights π
lowkey reminder bestie: everything above is exactly what the docs say, I just said it with more sparkle β¨
and that's the whole page!! footer era: this was rendered by perl v5.34.0 on 2022-06-14, under the name HTTP::...::Basic(3pm). byeee, go encode something π¦πΈ
π¦ where this page comes from
- debian bookworm: libhttp-headers-actionpack-perl 0.09-2 Β· Artistic-1.0-Perl OR GPL-1.0-or-later
- ubuntu noble: libhttp-headers-actionpack-perl 0.09-2 Β· Artistic-1.0-Perl OR GPL-1.0-or-later
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms