turnadmin
看了代码以后发现turnadmin和turnserver其实是一个程序,代码中判断了第一个命令行参数是否”turnadmin”来区别。
trunadmin的入口为:mainrealy.c的adminmain函数
1) For the long-term credentials there must be keys
“turn/realm//user//key” and the values must be
the the hmackeys. For example, for the user “gorst”, realm “north.gov”
and password “hero”, there must be key “turn/realm/north.gov/user/gorst/key”
with value “7da2270ccfa49786e0115366d3a3d14d”.
以上turndb/schema.userdb.redis中的说明,对应以下命令行:
./turnadmin -k -u gorst -p hero -r north.gov
返回:0x7da2270ccfa49786e0115366d3a3d14d