12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970 |
- #ifndef BOINC_CERT_SIG_H
- #define BOINC_CERT_SIG_H
- #include <vector>
- #include "parse.h"
- #define MAX_CERT_SIG_LEN 4096
- #define MAX_SUBJECT_LEN 256
- #define MD5_HASH 0
- #define SHA1_HASH 1
- struct CERT_SIG {
- char signature[MAX_CERT_SIG_LEN];
- int type;
- char subject[MAX_SUBJECT_LEN];
- char hash[9];
- CERT_SIG();
- ~CERT_SIG();
- void clear();
- };
- struct CERT_SIGS {
- std::vector<CERT_SIG> signatures;
- CERT_SIGS();
- ~CERT_SIGS();
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- int parse_file(const char* filename);
- int parse_buffer(char* buf);
- int write(MIOFILE &f);
- int parse_buffer_embed(char* buf);
- void clear();
- int count();
- int parse(XML_PARSER &xp);
- };
- #endif
|