1 | |
---|
2 | all: attr prove attr_partial |
---|
3 | |
---|
4 | abac_attr.o: abac_attr.c |
---|
5 | gcc -g -I/usr/local/include -c abac_attr.c -o abac_attr.o |
---|
6 | |
---|
7 | abac_attr: abac_attr.o |
---|
8 | gcc -g -o abac_attr abac_attr.o -L/usr/local/lib -L/usr/local/lib/ipsec -labac -lYap -lreadline -lm -lstrongswan -lpthread -Wl,-rpath -Wl,/usr/local/lib/ipsec |
---|
9 | |
---|
10 | abac_attr_partial.o: abac_attr_partial.c |
---|
11 | gcc -g -I/usr/local/include -c abac_attr_partial.c -o abac_attr_partial.o |
---|
12 | |
---|
13 | abac_attr_partial: abac_attr_partial.o |
---|
14 | gcc -g -o abac_attr_partial abac_attr_partial.o -L/usr/local/lib -L/usr/local/lib/ipsec -labac -lYap -lreadline -lm -lstrongswan -lpthread -Wl,-rpath -Wl,/usr/local/lib/ipsec |
---|
15 | |
---|
16 | abac_prover.o: abac_prover.c |
---|
17 | gcc -g -I/usr/local/include -c abac_prover.c -o abac_prover.o |
---|
18 | |
---|
19 | abac_prover: abac_prover.o |
---|
20 | gcc -g -o abac_prover abac_prover.o -L/usr/local/lib -L/usr/local/lib/ipsec -labac -lYap -lreadline -lm -lstrongswan -lpthread -Wl,-rpath -Wl,/usr/local/lib/ipsec |
---|
21 | |
---|
22 | tchunk: tchunk.c |
---|
23 | gcc -g -I/usr/local/include -c tchunk.c -o tchunk.o |
---|
24 | gcc -g -o tchunk tchunk.o -L/usr/local/lib -L/usr/local/lib/ipsec -labac -lYap -lreadline -lm -lstrongswan -lpthread -Wl,-rpath -Wl,/usr/local/lib/ipsec |
---|
25 | ./tchunk 0 IceCream_ID.pem IceCream_private.pem |
---|
26 | ./tchunk 1 IceCream_ID.pem IceCream_private.pem |
---|
27 | |
---|
28 | tt: tbasic.c |
---|
29 | gcc -g -I/usr/local/include -c tbasic.c -o tbasic.o |
---|
30 | gcc -g -o tt tbasic.o -L/usr/local/lib -L/usr/local/lib/ipsec -labac -lYap -lreadline -lm -lstrongswan -lpthread -Wl,-rpath -Wl,/usr/local/lib/ipsec |
---|
31 | |
---|
32 | clean: |
---|
33 | @rm -rf abac_attr.o abac_attr *.pem *.der abac_prover.o |
---|
34 | @rm -rf abac_prover *.log abac_attr_partial.o abac_attr_partial |
---|
35 | @rm -rf tt tbasic.o tbasic |
---|
36 | |
---|
37 | setup: abac_attr abac_prover abac_attr_partial |
---|
38 | creddy --generate --cn IceCream |
---|
39 | creddy --generate --cn Chocolate |
---|
40 | |
---|
41 | attr: |
---|
42 | rm -rf attr.log |
---|
43 | make setup |
---|
44 | ./abac_attr IceCream_ID.pem IceCream_private.pem IceCream_attr.der Chocolate_ID.pem 1>attr.log 2>&1 |
---|
45 | |
---|
46 | attr_partial: |
---|
47 | rm -rf attr_partial.log |
---|
48 | make setup |
---|
49 | ./abac_attr_partial IceCream_ID.pem IceCream_private.pem IceCream_attr.der Chocolate_ID.pem 1>attr_partial.log 2>&1 |
---|
50 | |
---|
51 | prove: |
---|
52 | rm -rf prover.log |
---|
53 | make attr |
---|
54 | ./run_prover 1>prover.log 2>&1 |
---|
55 | |
---|