Debian Codegraph @

lib/CPANSA/DB.pod

raw
1 # created by util/generate at Tue Sep 8 04:40:15 2026
2 # https://github.com/briandfoy/cpan-security-advisory.git a37bb050d2ebb51a4544d2f2b04b4b2d121ed9ea
3
4 =encoding utf8
5
6 =head1 NAME
7
8 CPANSA::DB - the CPAN Security Advisory data as a Perl data structure, mostly for CPAN::Audit
9
10 =head1 SYNOPSIS
11
12 This module is primarily used by L<CPAN::Audit>.
13
14 use CPANSA::DB;
15
16 my $db = CPANSA::DB->db;
17
18 =head1 DESCRIPTION
19
20 The C<db> subroutine returns the CPAN Security Advisory (CPANSA) reports
21 as a Perl data structure. However, anything can use this.
22
23 Each release also comes with a F<.gpg> file that has the signature
24 for the file. If you cannot confirm that the module file has the
25 right signature, it might have been corrupted or modified.
26
27 This module is available outside of CPAN as a release on GitHub:
28 L<https://github.com/briandfoy/cpan-security-advisory/releases>.
29 Each release on GitHub includes an attestation.
30
31 There is also a JSON file that provides the same datastructure.
32
33 =head2 Subroutines
34
35 There is exactly one subroutine:
36
37 =over 4
38
39 =item * db
40
41 Returns the hashref of all the CPANSA reports.
42
43 =back
44
45 =head1 VERIFYING
46
47 This distribution now uses
48 L<GitHub Attestations|https://github.blog/2024-05-02-introducing-artifact-attestations-now-in-public-beta/>,
49 which allow you to verify that the archive file you have was made from
50 the official repo.
51
52 You need a GitHub account and the L<gh tool|https://github.com/larsks/ghcli>.
53
54 # download the distro file from GitHub, MetaCPAN, or a CPAN mirror
55 $ gh auth login
56 ...follow instructions...
57 $ gh attestation verify CPANSA-DB-20241111.tar.gz --owner briandfoy
58
59 Additionally, each release codes with GPG signature that allows you to
60 verify that this. The key is the same one used when the database was
61 distributed with L<CPAN::Audit>:
62
63 $ gpg --verify lib/CPANSA/DB.pm.gpg lib/CPANSA/DB.pm
64 gpg: Signature made Mon Nov 18 11:00:10 2024 EST
65 gpg: using RSA key 75AAB42CBA0D7F37F0D6886DF83F8D5E878B6041
66 gpg: Good signature from "CPAN::Audit (brian d foy) (https://github.com/briandfoy/cpan-audit) <[email protected]>" [ultimate]
67
68 =head1 SEE ALSO
69
70 Everything is managed in GitHub:
71
72 =over 4
73
74 =item * L<https://github.com/briandfoy/cpan-security-advisory/releases>
75
76 =back
77
78 =cut
79