forked from abrasive/shairport
-
Notifications
You must be signed in to change notification settings - Fork 0
/
shairport.h
57 lines (48 loc) · 940 Bytes
/
shairport.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
#ifndef __SHAIRPORT_H__
#define __SHAIRPORT_H__
#include <stdio.h>
#include <string.h>
#include <unistd.h>
#include <openssl/bio.h>
#include <openssl/ssl.h>
#include <openssl/err.h>
#include "socketlib.h"
#include <regex.h>
#include <sys/types.h>
#include <sys/wait.h>
#include <regex.h>
#define HWID_SIZE 6
#define SHAIRPORT_LOG 1
#define LOG_INFO 1
#define LOG_DEBUG 5
#define LOG_DEBUG_V 6
#define LOG_DEBUG_VV 7
struct shairbuffer
{
char *data;
int current;
int maxsize;
int marker;
};
struct keyring
{
char *aeskey;
char *aesiv;
char *fmt;
};
struct comms
{
int in[2];
int out[2];
};
struct connection
{
struct shairbuffer recv;
struct shairbuffer resp;
struct keyring *keys; // Does not point to malloc'd memory.
struct comms *hairtunes;
int clientSocket;
char *password;
};
void sim(int pLevel, char *pValue1, char *pValue2);
#endif