summaryrefslogtreecommitdiffstats
path: root/openwrt/package/mini_httpd/files/matrixssl_helper.h
diff options
context:
space:
mode:
authornico <nico@3c298f89-4303-0410-b956-a3cf2f4a3e73>2005-06-17 06:22:46 +0000
committernico <nico@3c298f89-4303-0410-b956-a3cf2f4a3e73>2005-06-17 06:22:46 +0000
commit106201c1f26e92f6e5ec059f02f79dcf59cc9b95 (patch)
treeec1b19947b270053331e79345f6906beb93a9c17 /openwrt/package/mini_httpd/files/matrixssl_helper.h
parent7f05a82f019a6b58841841f86d388cbb9f8ae306 (diff)
Add mini_httpd package
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@1267 3c298f89-4303-0410-b956-a3cf2f4a3e73
Diffstat (limited to 'openwrt/package/mini_httpd/files/matrixssl_helper.h')
-rw-r--r--openwrt/package/mini_httpd/files/matrixssl_helper.h39
1 files changed, 39 insertions, 0 deletions
diff --git a/openwrt/package/mini_httpd/files/matrixssl_helper.h b/openwrt/package/mini_httpd/files/matrixssl_helper.h
new file mode 100644
index 000000000..e5854df64
--- /dev/null
+++ b/openwrt/package/mini_httpd/files/matrixssl_helper.h
@@ -0,0 +1,39 @@
+/*
+ * MatrixSSL helper functions
+ *
+ * Copyright (C) 2005 Nicolas Thill <nthill@free.fr>
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ */
+
+#ifndef __MATRIXSSL_HELPER_H__
+#define __MATRIXSSL_HELPER_H__
+
+#include <matrixSsl/matrixSsl.h>
+
+typedef struct __SSL {
+ int fd;
+ ssl_t *ssl;
+ sslKeys_t *keys;
+ sslBuf_t insock, outsock, inbuf;
+ int outBufferCount;
+ int partial;
+ int status;
+} SSL;
+
+SSL * SSL_new(sslKeys_t *keys);
+void SSL_set_fd(SSL *ssl, int fd);
+int SSL_accept(SSL *ssl);
+int SSL_read(SSL *ssl, char *b, int len);
+int SSL_write(SSL *ssl, char *buf, int len);
+void SSL_free(SSL *ssl);
+
+#endif /* __MATRIXSSL_HELPER_H__ */