GnuPG::UserId(3pm)
π GnuPG::UserId β GnuPG User ID Objects
So this is the GnuPG::UserId(3pm) page, bestie β part of the User Contributed Perl Documentation, and honestly? It's a little baddie. Let's get into it. π
β¨ SYNOPSIS β¨
Okay so picture this: you've got a GnuPG::PublicKey object chilling in $publickey, and you wanna grab the first user ID off it as a plain string. Boom. Iconic.
# assumes a GnuPG::PublicKey object in $publickey
my $user_id = $publickey->user_ids_ref->[0]->as_string;
That's it. That's the whole vibe check. π¦
πΈ DESCRIPTION πΈ
So here's the tea: these GnuPG::UserId objects are generally not instantiated on their own. Like, they're not out here living their solo main character life. They show up as part of GnuPG::PublicKey or GnuPG::SecretKey objects instead β supporting cast, but make it essential. π
π OBJECT METHODS π
new( %initialization_args )
This method creates a new object. The arguments are optional, and what are they, exactly? They're initialization of data members. Lowkey self-explanatory but we said what we said. β¨
compare( $other, $deep )
Returns non-zero only when this User ID is identical to the other GnuPG::UserID. That's the whole rule, no exceptions, periodt.
Now, if $deep is present and non-zero, then the User ID's signatures and revocations get compared too β like a deep dive into the whole friend group instead of just the profile pic. π«Ά
π OBJECT DATA MEMBERS π
as_stringβ A string of the user id. Literally just the user ID, as a string. Slay. πvalidityβ A scalar holding the value GnuPG reports for the trust of authenticity (a.k.a.) validity of a key. For the deets, go check GnuPG'sDETAILSfile β iykyk. πsignaturesβ A list ofGnuPG::Signatureobjects embodying the signatures on this user id. The whole entourage. πrevocationsβ A list of revocations associated with this User ID, stored asGnuPG::Signatureobjects. Why? Because revocations are a type of certification as well β so they get the same object treatment. No cap. π
β SEE ALSO β
GnuPG::Signature,
Fr fr, that's the whole page. Nothing skipped, nothing hidden. You're welcome bestie. ππ
And that's the wrap! π§ This absolute gem of a page came to you courtesy of perl v5.40.1, dated 2025-03-14 β go off, GnuPG::UserId(3pm), you ate. ππ₯
π¦ where this page comes from
- debian trixie: libgnupg-interface-perl 1.04-6 Β· Artistic-1.0-Perl OR GPL-1.0-or-later
- ubuntu resolute: libgnupg-interface-perl 1.04-6 Β· Artistic-1.0-Perl OR GPL-1.0-or-later
- ubuntu stonking: libgnupg-interface-perl 1.04-6 Β· Artistic-1.0-Perl OR GPL-1.0-or-later
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms