]> git.sur5r.net Git - ngadmin/blob - lib/src/network.h
6ed3cde28324ad8ec7254d82d99c7bd2ba254601
[ngadmin] / lib / src / network.h
1
2 #ifndef DEF_NETWORK
3 #define DEF_NETWORK
4
5
6 #include <string.h>
7 #include <unistd.h>
8 #include <arpa/inet.h>
9 #include <net/if.h>
10 #include <netinet/ether.h>
11 #include <sys/ioctl.h>
12
13 #include "list.h"
14 #include "lib.h"
15 #include "protocol.h"
16
17
18
19
20 // 
21 int startNetwork (struct ngadmin *nga);
22
23 // 
24 int stopNetwork (struct ngadmin *nga);
25
26 // 
27 int forceInterface (struct ngadmin *nga);
28
29 // 
30 int updateTimeout (struct ngadmin *nga);
31
32 // 
33 int sendNgPacket (struct ngadmin *nga, char code, const List *attr);
34
35 // 
36 int recvNgPacket (struct ngadmin *nga, char code, unsigned char *error, unsigned short *attr_error, List *attr);
37
38 // 
39 int readRequest (struct ngadmin *nga, List *attr);
40
41 // 
42 int writeRequest (struct ngadmin *nga, List *attr);
43
44
45
46 #endif
47