Skip to content

Commit

Permalink
trival
Browse files Browse the repository at this point in the history
  • Loading branch information
wangyu- committed Aug 21, 2017
1 parent dd8539e commit 033fa83
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 2 deletions.
19 changes: 18 additions & 1 deletion main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2214,6 +2214,18 @@ int server_event_loop()

bind_address_uint32=local_ip_uint32;//only server has bind adress,client sets it to zero

if(lower_level)
{
if(lower_level_manual)
{
mylog(log_info,"we are running at lower-level (manual) mode\n");
}
else
{
mylog(log_info,"we are running at lower-level (auto) mode\n");
}

}

if(raw_mode==mode_faketcp)
{
Expand Down Expand Up @@ -2493,7 +2505,8 @@ void print_help()
printf(" --cipher-mode <string> avaliable values:aes128cbc(default),xor,none\n");
printf(" --auth-mode <string> avaliable values:md5(default),crc32,simple,none\n");
printf(" -a,--auto-rule auto add (and delete) iptables rule\n");
printf(" -g,--gen-rule generate iptables rule then exit,overrides -a\n");
printf(" -g,--gen-rule generate iptables rule then exit,so that you can copy and\n");
printf(" add it manually.overrides -a\n");
printf(" --disable-anti-replay disable anti-replay,not suggested\n");

//printf("\n");
Expand Down Expand Up @@ -2723,6 +2736,10 @@ void process_arg(int argc, char *argv[])
if(strcmp(optarg,auth_mode_tostring[i])==0)
{
auth_mode=(auth_mode_t)i;
if(auth_mode==auth_none)
{
disable_anti_replay=1;
}
break;
}
}
Expand Down
2 changes: 1 addition & 1 deletion makefile
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ cc_bcm2708=/home/wangyu/raspberry/tools/arm-bcm2708/gcc-linaro-arm-linux-gnueabi
cc_arm=/home/wangyu/Desktop/arm-2014.05/bin/arm-none-linux-gnueabi-g++
FLAGS= -std=c++11 -Wall -Wextra -Wno-unused-variable -Wno-unused-parameter -Wno-missing-field-initializers

SOURCES=main.cpp lib/aes.c lib/md5.c encrypt.cpp log.cpp network.cpp common.cpp -lrt -lpthread
SOURCES=main.cpp lib/aes.c lib/md5.c encrypt.cpp log.cpp network.cpp common.cpp -lpthread
SOURCES_AES_ACC=$(filter-out lib/aes.c,$(SOURCES)) $(wildcard lib/aes_acc/aes*.c)

NAME=udp2raw
Expand Down

0 comments on commit 033fa83

Please sign in to comment.