1gnutls_x509_crt_set_version(3)      gnutls      gnutls_x509_crt_set_version(3)
2
3
4

NAME

6       gnutls_x509_crt_set_version - API function
7

SYNOPSIS

9       #include <gnutls/x509.h>
10
11       int  gnutls_x509_crt_set_version(gnutls_x509_crt_t  crt,  unsigned  int
12       version);
13

ARGUMENTS

15       gnutls_x509_crt_t crt
16                   a certificate of type gnutls_x509_crt_t
17
18       unsigned int version
19                   holds the version number. For X.509v1 certificates must  be
20                   1.
21

DESCRIPTION

23       This  function  will  set the version of the certificate.  This must be
24       one for X.509 version 1, and so on.  Plain certificates without  exten‐
25       sions must have version set to one.
26
27       To  create  well-formed certificates, you must specify version 3 if you
28       use any certificate extensions.  Extensions are  created  by  functions
29       such         as        gnutls_x509_crt_set_subject_alt_name()        or
30       gnutls_x509_crt_set_key_usage().
31

RETURNS

33       On success, GNUTLS_E_SUCCESS (0) is returned, otherwise a negative  er‐
34       ror value.
35

REPORTING BUGS

37       Report bugs to <bugs@gnutls.org>.
38       Home page: https://www.gnutls.org
39
40
42       Copyright © 2001- Free Software Foundation, Inc., and others.
43       Copying  and  distribution  of this file, with or without modification,
44       are permitted in any medium without royalty provided the copyright  no‐
45       tice and this notice are preserved.
46

SEE ALSO

48       The  full  documentation  for gnutls is maintained as a Texinfo manual.
49       If the /usr/share/doc/gnutls/ directory does not contain the HTML  form
50       visit
51
52       https://www.gnutls.org/manual/
53
54gnutls                               3.7.8      gnutls_x509_crt_set_version(3)
Impressum