Identify the hash algorithm from a PGP signature. More...
#include "config.h"#include <stdbool.h>#include <stdio.h>#include <string.h>#include "mutt/lib.h"#include "core/lib.h"#include "pgpmicalg.h"#include "handler.h"#include "pgppacket.h"
Include dependency graph for pgpmicalg.c:Go to the source code of this file.
Data Structures | |
| struct | HashAlgorithm |
| PGP Hashing algorithm. More... | |
Functions | |
| static const char * | pgp_hash_to_micalg (short id) |
| Lookup a hash name, given its id. | |
| static void | pgp_dearmor (FILE *fp_in, FILE *fp_out) |
| Unwrap an armoured PGP block. | |
| static short | pgp_mic_from_packet (unsigned char *p, size_t len) |
| Get the hash algorithm from a PGP packet. | |
| static short | pgp_find_hash (const char *fname) |
| Find the hash algorithm of a file. | |
| const char * | pgp_micalg (const char *fname) |
| Find the hash algorithm of a file. | |
Variables | |
| static const struct HashAlgorithm | HashAlgorithms [] |
| PGP Hashing algorithms. | |
Identify the hash algorithm from a PGP signature.
This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
You should have received a copy of the GNU General Public License along with this program. If not, see http://www.gnu.org/licenses/.
Definition in file pgpmicalg.c.
|
static |
Lookup a hash name, given its id.
| id | ID |
| ptr | Name of hash algorithm |
Definition at line 64 of file pgpmicalg.c.
Here is the caller graph for this function:
|
static |
Unwrap an armoured PGP block.
| fp_in | File to read from |
| fp_out | File to write to |
Definition at line 77 of file pgpmicalg.c.
Here is the call graph for this function:
Here is the caller graph for this function:
|
static |
Get the hash algorithm from a PGP packet.
| p | PGP packet |
| len | Length of packet |
| num | Hash algorithm id |
Definition at line 152 of file pgpmicalg.c.
Here is the caller graph for this function:
|
static |
Find the hash algorithm of a file.
| fname | File to read |
| num | Hash algorithm id |
Definition at line 183 of file pgpmicalg.c.
Here is the call graph for this function:
Here is the caller graph for this function:| const char * pgp_micalg | ( | const char * | fname | ) |
Find the hash algorithm of a file.
| fname | File to read |
| ptr | Name of hash algorithm |
Definition at line 228 of file pgpmicalg.c.
Here is the call graph for this function:
Here is the caller graph for this function:
|
static |
PGP Hashing algorithms.
Definition at line 52 of file pgpmicalg.c.