summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--.vscode/ftp-kr.sync.cache.json49
-rw-r--r--access/src/ip_mgr.cpp3
-rw-r--r--create_tun.sh3
3 files changed, 27 insertions, 28 deletions
diff --git a/.vscode/ftp-kr.sync.cache.json b/.vscode/ftp-kr.sync.cache.json
index 5d02977..e366664 100644
--- a/.vscode/ftp-kr.sync.cache.json
+++ b/.vscode/ftp-kr.sync.cache.json
@@ -57,8 +57,8 @@
},
"mgw_tun.cpp": {
"type": "-",
- "size": 2513,
- "lmtime": 1542856595431,
+ "size": 2598,
+ "lmtime": 1543374190079,
"modified": false
}
},
@@ -130,8 +130,8 @@
"src": {
"main.cpp": {
"type": "-",
- "size": 16408,
- "lmtime": 1543325721962,
+ "size": 16638,
+ "lmtime": 1543409951644,
"modified": false
},
"tun.cpp": {
@@ -142,14 +142,14 @@
},
"vpn_monitor.cpp": {
"type": "-",
- "size": 9250,
- "lmtime": 1543236257310,
+ "size": 9249,
+ "lmtime": 1543372925586,
"modified": false
},
"nat.cpp": {
"type": "-",
- "size": 24641,
- "lmtime": 1543325655332,
+ "size": 23249,
+ "lmtime": 1543410118010,
"modified": false
},
"ip_translator.cpp": {
@@ -172,8 +172,8 @@
},
"ip_mgr.cpp": {
"type": "-",
- "size": 17464,
- "lmtime": 1543325742644,
+ "size": 17432,
+ "lmtime": 1543461860280,
"modified": false
},
"udp_server.cpp": {
@@ -279,30 +279,29 @@
"modified": false
}
},
- "Makefile": {
- "type": "-",
- "size": 5841,
- "lmtime": 0,
- "modified": true
- },
"CMakeLists.txt": {
"type": "-",
"size": 459,
"lmtime": 1542863950666,
"modified": false
},
- "CMakeFiles": {},
- "CMakeCache.txt": {
+ "create_tun.sh": {
"type": "-",
- "size": 13301,
- "lmtime": 0,
- "modified": true
+ "size": 324,
+ "lmtime": 1543460762526,
+ "modified": false
},
- "cmake_install.cmake": {
+ ".gitignore.swp": {
"type": "-",
- "size": 1756,
- "lmtime": 0,
- "modified": true
+ "size": 4096,
+ "lmtime": 1543411055423,
+ "modified": false
+ },
+ ".gitignore": {
+ "type": "-",
+ "size": 18,
+ "lmtime": 1543411187230,
+ "modified": false
}
}
}
diff --git a/access/src/ip_mgr.cpp b/access/src/ip_mgr.cpp
index 020a882..73e582d 100644
--- a/access/src/ip_mgr.cpp
+++ b/access/src/ip_mgr.cpp
@@ -193,10 +193,9 @@ static void Maat_user_policy_finish_cb(void* args)
static void Maat_cand_ip_start_cb(int update_type,void* args)
{
- printf("Maat_cand_ip_start_cb: update_type is %d\n", update_type);
struct ip_mgr_handle *handle = (struct ip_mgr_handle *)args;
void *logger = handle->logger;
- MGW_LOG_INFO(logger, "Maat_redis: start callback, table is CAND_IP_TABLE");
+ MGW_LOG_INFO(logger, "Maat_redis: start callback, table is CAND_IP_TABLE, updata_type is %d\n", update_type);
return;
}
diff --git a/create_tun.sh b/create_tun.sh
index 9c6efb6..c7b03a7 100644
--- a/create_tun.sh
+++ b/create_tun.sh
@@ -1,6 +1,7 @@
#!/bin/sh
ip addr add 192.168.30.254/24 dev tap_softether
-ip tuntap add dev tun_mgw mode tun && ifconfig tun_mgw up
+ip tuntap add dev tun_mgw mode tun
+ifconfig tun_mgw up
ip rule add iif tap_softether tab 100
ip route add default dev tun_mgw table 100
echo 1 > /proc/sys/net/ipv4/ip_forward