summaryrefslogtreecommitdiff
path: root/src/include
diff options
context:
space:
mode:
authorLaurent Bercot <ska-skaware@skarnet.org>2017-01-10 02:17:16 +0000
committerLaurent Bercot <ska-skaware@skarnet.org>2017-01-10 02:17:16 +0000
commit334d807b924427434b42d4fbae745d3d1b38a218 (patch)
tree6daf12c1e2fa07d2ac6255ef4439e2fb95a57f57 /src/include
parent43cb3ee4227de70e0225e9ac142b4d397f93cc41 (diff)
downloads6-networking-334d807b924427434b42d4fbae745d3d1b38a218.tar.xz
Types fix, first pass
XXX marks what must change when skalibs changes. Also started writing functions for client certificate support in sbearssl, but it's not working yet (need more high-level support from BearSSL before it can work)
Diffstat (limited to 'src/include')
-rw-r--r--src/include/s6-networking/ident.h9
-rw-r--r--src/include/s6-networking/sbearssl.h4
-rw-r--r--src/include/s6-networking/stls.h1
3 files changed, 10 insertions, 4 deletions
diff --git a/src/include/s6-networking/ident.h b/src/include/s6-networking/ident.h
index 723fc89..4a406b5 100644
--- a/src/include/s6-networking/ident.h
+++ b/src/include/s6-networking/ident.h
@@ -3,7 +3,8 @@
#ifndef IDENT1413_H
#define IDENT1413_H
-#include <skalibs/uint16.h>
+#include <sys/types.h>
+#include <stdint.h>
#include <skalibs/tai.h>
#include <skalibs/ip46.h>
@@ -12,15 +13,15 @@
/* High-level */
-extern int s6net_ident_client (char *, unsigned int, ip46_t const *, uint16, ip46_t const *, uint16, tain_t const *, tain_t *) ;
+extern int s6net_ident_client (char *, size_t, ip46_t const *, uint16_t, ip46_t const *, uint16_t, tain_t const *, tain_t *) ;
#define s6net_ident_client_g(s, max, ra, rp, la, lp, deadline) s6net_ident_client(s, max, ra, rp, la, lp, (deadline), &STAMP)
extern char const *s6net_ident_error_str (int) ;
/* Low-level */
-extern int s6net_ident_reply_get (char *, ip46_t const *, uint16, ip46_t const *, uint16, tain_t const *, tain_t *) ;
+extern ssize_t s6net_ident_reply_get (char *, ip46_t const *, uint16_t, ip46_t const *, uint16_t, tain_t const *, tain_t *) ;
#define s6net_ident_reply_get_g(s, ra, rp, la, lp, deadline) s6net_ident_reply_get(s, ra, rp, la, lp, (deadline), &STAMP)
-extern int s6net_ident_reply_parse (char const *, uint16, uint16) ;
+extern ssize_t s6net_ident_reply_parse (char const *, uint16_t, uint16_t) ;
#endif
diff --git a/src/include/s6-networking/sbearssl.h b/src/include/s6-networking/sbearssl.h
index dba1742..785e647 100644
--- a/src/include/s6-networking/sbearssl.h
+++ b/src/include/s6-networking/sbearssl.h
@@ -4,6 +4,7 @@
#define SBEARSSL_H
#include <sys/types.h>
+#include <stdint.h>
#include <bearssl.h>
#include <skalibs/buffer.h>
#include <skalibs/stralloc.h>
@@ -190,6 +191,9 @@ extern int sbearssl_ta_certs (genalloc *, stralloc *, sbearssl_cert const *, siz
extern int sbearssl_ta_readfile (char const *, genalloc *, stralloc *) ;
extern int sbearssl_ta_readdir (char const *, genalloc *, stralloc *) ;
+extern size_t sbearssl_x500_name_len (sbearssl_ta const *, size_t) ;
+extern void sbearssl_x500_from_ta (br_x500_name *, sbearssl_ta const *, size_t, char *, char const *) ;
+
/* Errors */
diff --git a/src/include/s6-networking/stls.h b/src/include/s6-networking/stls.h
index dbb55fe..9e418b1 100644
--- a/src/include/s6-networking/stls.h
+++ b/src/include/s6-networking/stls.h
@@ -4,6 +4,7 @@
#define STLS_H
#include <sys/types.h>
+#include <stdint.h>
#include <tls.h>
#include <skalibs/tai.h>