~ubuntu-branches/ubuntu/maverick/gnutls26/maverick-updates

« back to all changes in this revision

Viewing changes to tests/parse_ca.c

  • Committer: Bazaar Package Importer
  • Author(s): Andreas Metzler
  • Date: 2009-04-14 14:23:19 UTC
  • mfrom: (1.1.5 upstream)
  • Revision ID: james.westby@ubuntu.com-20090414142319-ok7xejzbqkofno1q
Tags: 2.6.5-1
* Sync sections in debian/control with override file. libgnutls26-dbg is
  section debug, guile-gnutls is section lisp.
* New upstream version. (Needed for Libtasn1-3 2.0)
* New patch 15_tasn1inpc.diff. Make sure libtasn1 is listed in Libs.private.
* Standards-Version: 3.8.1, no changes required.

Show diffs side-by-side

added added

removed removed

Lines of Context:
28
28
 
29
29
#include "utils.h"
30
30
 
31
 
const static char castr[] =
 
31
static char castr[] =
32
32
  "-----BEGIN CERTIFICATE-----\r\n"
33
33
  "MIIB5zCCAVKgAwIBAgIERiYdJzALBgkqhkiG9w0BAQUwGTEXMBUGA1UEAxMOR251\r\n"
34
34
  "VExTIHRlc3QgQ0EwHhcNMDcwNDE4MTMyOTExWhcNMDgwNDE3MTMyOTExWjAZMRcw\r\n"
53
53
  "Viyi4cBTJ8jylTALBgkqhkiG9w0BAQUDgYEAiaIRqGfp1jPpNeVhABK60SU0KIAy\r\n"
54
54
  "njuu7kHq5peUgYn8Jd9zNzExBOEp1VOipGsf6G66oQAhDFp2o8zkz7ZH71zR4HEW\r\n"
55
55
  "KoX6n5Emn6DvcEH/9pAhnGxNHJAoS7czTKv/JDZJhkqHxyrE1fuLsg5Qv25DTw7+\r\n"
56
 
  "PfqUpIhz5Bbm7J4=\r\n"
57
 
  "-----END CERTIFICATE-----\r\n";
 
56
  "PfqUpIhz5Bbm7J4=\r\n" "-----END CERTIFICATE-----\r\n";
58
57
 
59
58
void
60
59
doit (void)
63
62
  gnutls_certificate_credentials_t cred;
64
63
  gnutls_datum_t ca = { castr, sizeof (castr) };
65
64
 
66
 
  gnutls_global_init();
 
65
  gnutls_global_init ();
67
66
 
68
67
  rc = gnutls_certificate_allocate_credentials (&cred);
69
68
  if (rc)
75
74
 
76
75
  gnutls_certificate_free_credentials (cred);
77
76
 
78
 
  gnutls_global_deinit();
 
77
  gnutls_global_deinit ();
79
78
 
80
79
  success ("import ok\n");
81
80
}