locoz
2018-03-04 17:09:03 +08:00
events 是鼠标在页面里停留的位置和时间 fp 可以直接随机生成一下 ts 和 nts 是时间戳不用说了吧
"{"a":{"ts":1520152823,"events":[{"ts":73,"t":"mm","x":101,"y":27},{"ts":73,"t":"mm","x":103,"y":10},{"ts":73,"t":"mm","x":103,"y":4}......]},"fp":"4dba123c2b5b2e4f123a5c936aabcd","nts":1520152978}"
加密部分:
```
t.encode = function(e){
var t, n, r = {}, i = (e + "").split(""), o = [], a = i[0], s = 256;
for (t = 1; t < i.length; t++)
n = i[t],
r[a + n] ? a += n : (o.push(a.length > 1 ? r[a] : a.charCodeAt(0)),
r[a + n] = s,
s++,
a = n);
for (o.push(a.length > 1 ? r[a] : a.charCodeAt(0)),
t = 0; t < o.length; t++)
o[t] = String.fromCharCode(o[t]);
return o.join("")
}
```