Mercurial > pidgin
comparison libpurple/certificate.c @ 32414:7ceb5ca4b323
Add a function for retrieving the raw DER representation of a
certification.
author | Elliott Sales de Andrade <qulogic@pidgin.im> |
---|---|
date | Fri, 23 Dec 2011 01:09:13 +0000 |
parents | 1bcedeb32bb4 |
children | 298080cecdc5 |
comparison
equal
deleted
inserted
replaced
32413:82e524e447f1 | 32414:7ceb5ca4b323 |
---|---|
497 | 497 |
498 /* Throw the request on down to the certscheme */ | 498 /* Throw the request on down to the certscheme */ |
499 return (scheme->get_times)(crt, activation, expiration); | 499 return (scheme->get_times)(crt, activation, expiration); |
500 } | 500 } |
501 | 501 |
502 GByteArray * | |
503 purple_certificate_get_der_data(PurpleCertificate *crt) | |
504 { | |
505 PurpleCertificateScheme *scheme; | |
506 GByteArray *data; | |
507 | |
508 g_return_val_if_fail(crt, NULL); | |
509 g_return_val_if_fail(crt->scheme, NULL); | |
510 | |
511 scheme = crt->scheme; | |
512 | |
513 g_return_val_if_fail(scheme->get_der_data, NULL); | |
514 | |
515 data = (scheme->get_der_data)(crt); | |
516 | |
517 return data; | |
518 } | |
519 | |
502 gchar * | 520 gchar * |
503 purple_certificate_pool_mkpath(PurpleCertificatePool *pool, const gchar *id) | 521 purple_certificate_pool_mkpath(PurpleCertificatePool *pool, const gchar *id) |
504 { | 522 { |
505 gchar *path; | 523 gchar *path; |
506 gchar *esc_scheme_name, *esc_name, *esc_id; | 524 gchar *esc_scheme_name, *esc_name, *esc_id; |