Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
NetWork
Opentracker
提交
dc90c886
O
Opentracker
项目概览
NetWork
/
Opentracker
通知
0
Star
0
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
DevOps
流水线
流水线任务
计划
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
O
Opentracker
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
DevOps
DevOps
流水线
流水线任务
计划
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
流水线任务
提交
Issue看板
前往新版Gitcode,体验更适合开发者的 AI 搜索 >>
提交
dc90c886
编写于
5月 28, 2012
作者:
E
erdgeist
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
Report connection id missmatch count
上级
37db5f94
变更
3
隐藏空白更改
内联
并排
Showing
3 changed file
with
5 addition
and
5 deletion
+5
-5
Makefile
Makefile
+1
-1
ot_stats.c
ot_stats.c
+3
-3
ot_udp.c
ot_udp.c
+1
-1
未找到文件。
Makefile
浏览文件 @
dc90c886
...
...
@@ -35,7 +35,7 @@ BINDIR?=$(PREFIX)/bin
#FEATURES+=-DWANT_MODEST_FULLSCRAPES
#FEATURES+=-DWANT_SPOT_WOODPECKER
#FEATURES+=-DWANT_SYSLOGS
#
FEATURES+=-DWANT_DEV_RANDOM
FEATURES
+=
-DWANT_DEV_RANDOM
FEATURES
+=
-DWANT_FULLSCRAPE
#FEATURES+=-D_DEBUG_HTTPERROR
...
...
ot_stats.c
浏览文件 @
dc90c886
...
...
@@ -48,6 +48,7 @@ static unsigned long long ot_overall_tcp_successfulannounces = 0;
static
unsigned
long
long
ot_overall_udp_successfulannounces
=
0
;
static
unsigned
long
long
ot_overall_tcp_successfulscrapes
=
0
;
static
unsigned
long
long
ot_overall_udp_successfulscrapes
=
0
;
static
unsigned
long
long
ot_overall_udp_connectionidmissmatches
=
0
;
static
unsigned
long
long
ot_overall_tcp_connects
=
0
;
static
unsigned
long
long
ot_overall_udp_connects
=
0
;
static
unsigned
long
long
ot_overall_completed
=
0
;
...
...
@@ -59,7 +60,6 @@ static char * ot_failed_request_names[] = { "302 Redirect", "400 Par
static
unsigned
long
long
ot_renewed
[
OT_PEER_TIMEOUT
];
static
unsigned
long
long
ot_overall_sync_count
;
static
unsigned
long
long
ot_overall_stall_count
;
static
unsigned
long
long
g_stats_connid_missmatches
;
static
time_t
ot_start_time
;
...
...
@@ -539,7 +539,7 @@ static size_t stats_return_everything( char * reply ) {
r
+=
sprintf
(
r
,
" <completed>
\n
<count>%llu</count>
\n
</completed>
\n
"
,
ot_overall_completed
);
r
+=
sprintf
(
r
,
" <connections>
\n
"
);
r
+=
sprintf
(
r
,
" <tcp>
\n
<accept>%llu</accept>
\n
<announce>%llu</announce>
\n
<scrape>%llu</scrape>
\n
</tcp>
\n
"
,
ot_overall_tcp_connections
,
ot_overall_tcp_successfulannounces
,
ot_overall_udp_successfulscrapes
);
r
+=
sprintf
(
r
,
" <udp>
\n
<overall>%llu</overall>
\n
<connect>%llu</connect>
\n
<announce>%llu</announce>
\n
<scrape>%llu</scrape>
\n
</udp>
\n
"
,
ot_overall_udp_connections
,
ot_overall_udp_connects
,
ot_overall_udp_successfulannounces
,
ot_overall_udp_successfulscrap
es
);
r
+=
sprintf
(
r
,
" <udp>
\n
<overall>%llu</overall>
\n
<connect>%llu</connect>
\n
<announce>%llu</announce>
\n
<scrape>%llu</scrape>
\n
<missmatch>%llu</missmatch>
\n
</udp>
\n
"
,
ot_overall_udp_connections
,
ot_overall_udp_connects
,
ot_overall_udp_successfulannounces
,
ot_overall_udp_successfulscrapes
,
ot_overall_udp_connectionidmissmatch
es
);
r
+=
sprintf
(
r
,
" <livesync>
\n
<count>%llu</count>
\n
</livesync>
\n
"
,
ot_overall_sync_count
);
r
+=
sprintf
(
r
,
" </connections>
\n
"
);
r
+=
sprintf
(
r
,
" <debug>
\n
"
);
...
...
@@ -725,7 +725,7 @@ void stats_issue_event( ot_status_event event, PROTO_FLAG proto, uintptr_t event
break
;
#endif
case
EVENT_CONNID_MISSMATCH
:
++
g_stats_connid_
missmatches
;
++
ot_overall_udp_connectionid
missmatches
;
default:
break
;
}
...
...
ot_udp.c
浏览文件 @
dc90c886
...
...
@@ -38,7 +38,7 @@ static void udp_generate_rijndael_round_key() {
static
void
udp_make_connectionid
(
uint32_t
connid
[
4
],
const
ot_ip6
remoteip
)
{
uint32_t
plain
[
4
],
crypt
[
4
];
int
age
,
i
;
for
(
i
=
0
;
i
<
16
;
++
i
)
fprintf
(
stderr
,
"%02uX "
,
(
uint8_t
)
remoteip
[
i
]
);
fprintf
(
stderr
,
"
\n
"
);
if
(
g_now_minutes
+
60
>
g_hour_of_the_key
)
{
g_hour_of_the_key
=
g_now_minutes
;
g_key_of_the_hour
[
1
]
=
g_key_of_the_hour
[
0
];
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录