wolfssl Initial

pull/2/head
kaleb-himes 2015-01-09 16:44:54 -07:00
parent e992da5fba
commit c20b82925b
6 changed files with 7 additions and 6 deletions

View File

@ -1,6 +1,6 @@
CC=gcc
CFLAGS=-Wall
LIBS= -lcyassl
LIBS= -lwolfssl
camellia-encrypt: camellia-encrypt.o
$(CC) -o $@ $^ $(CFLAGS) $(LIBS)

View File

@ -1,6 +1,6 @@
CC=gcc
CFLAGS=-Wall -DCYASSL_DTLS
LIBS=-lcyassl -lpthread
CFLAGS=-Wall -DWOLFSSL_DTLS
LIBS=-lwolfssl -lpthread
all: client-udp client-dtls client-dtls-nonblocking client-dtls-resume server-udp server-dtls server-dtls-nonblocking server-dtls-threaded

View File

@ -1,6 +1,6 @@
CC=gcc
CFLAGS=-Wall
LIBS=-lcyassl
LIBS=-lwolfssl
all: client-tcp client-psk client-psk-nonblocking client-psk-resume server-tcp server-psk server-psk-nonblocking server-psk-threaded

View File

@ -1,6 +1,6 @@
CC=gcc
CFLAGS=-Wall
LIBS=-lcyassl
LIBS=-lwolfssl
all: client-tcp client-tls client-tls-nonblocking client-tls-resume client-callback server-tcp server-tls server-tls-nonblocking server-tls-threaded server-callback

View File

@ -25,6 +25,7 @@
#include <arpa/inet.h>
#include <cyassl/ssl.h> /* CyaSSL security library */
#include <fcntl.h> /* nonblocking I/O library */
#include <sys/select.h>
#define MAXDATASIZE 4096 /* maximum acceptable amount of data */
#define SERV_PORT 11111 /* define default port number */

View File

@ -179,7 +179,7 @@ int Server(word16 port)
CyaSSL_SetIORecv(ctx, CbIORecv);
CyaSSL_SetIOSend(ctx, CbIOSend);
tcp_accept(&listenfd, &connfd, NULL, port, 1, 0);
tcp_accept(&listenfd, &connfd, NULL, port, 1, 0, 0);
if (connfd < 0) {
err_sys("Fatal error : accept error");