Location:
Clients-----|----> Proxy GATE-----|----> Gserver
|| Nginx---------------->http-lua-mode nginx-net.api ===> URL, Post/get, Socket and so on ..... (role by Web server)
|| Network data=============================================================================
|| Time255 (60-second frequency generation key) ==>gen and check the key, use 1 byte for check in the pack
|| Msgpack:packdata = Msgpack (rspdata); packdata = Msgpack (#packdata): Packdata
|| Xxtea:encrypt---(PACKDTA)---> encrystr (binary data)
|| package:time255 + | | Msgpack (Rspdata)
|| Xxtea [Msgpack data] =====>gen package
======================================================================
======================================================================
|| Time255 = Nginx api.get ()----|---> String.sub (reqdata, 1, 1) (Time255 len:1 byte)
|| Already Xxtea and Msgpack-on-the-data
||
|| Msgpack data<----------------(xxtea.decrypt)
||
|| Msgpack (#packdata): packdata<----------------------(Headoffset, Headlen)
||
(Totallen, Rspdata)------------------>rspdata=========>unpack Data
Important:gen encrypt key by time255,time 60s change and key WORDS
KEY WORDS:
3. . ? . . X. . <. .~ . . g
# . . ` . . _ . . - . .5. . V
! . . \ . . | . . } . . &. . 0
* . . / . . + . . B. . I. . |
Q. . (.. K. T: O.. P
o L . = . . $ . . {.. u: H
Do not reprint without permission.
Copyright NOTICE: This article for Bo Master original article, without Bo Master permission not reproduced.
Linux Http-lua-mode msgpack (network data)