js & anti craw & crawler spam

demo & X-Sign


, function(t, e, n) {
"use strict";
var r = n(126)
, o = n.n(r)
, i = "WSUDD"
, a = "X"
, s = "/fe_api/";
e.a = {
name: "crawler-spam",
install: function(t, e) {
e.isBrowser && e.http.interceptors.dispatch.use(function(t) {
return t.url.indexOf(s) > -1 && (t.headers["X-Sign"] = function(t, e) {
var n = arguments.length > 2 && void 0 !== arguments[2] ? arguments[2] : a
, r = t.url
, u = void 0 === r ? "" : r
, c = t.params
, f = t.paramsSerializer;
return u = u.slice(u.indexOf(s), u.length),
n === a ? "" + n + o()(e(u, c, f) + i) : ""
}(t, e.http.buildURL)),
t
})
}
}
}
  1. step 1: find crawler spam js file name & get json data

js & XHR

  1. open sources, set break points

js files

  1. debug, find the logic

step by step, look for the roots(溯源)

  1. mock / fake, craw datas

blogs

crawler-spam

https://www.xiaohongshu.com/page/hot

https://www.xiaohongshu.com/explore

https://www.edificeautomotive.com/blog/2016/02/26/ghost-and-crawler-spam/

referral exclusion list

https://support.google.com/analytics/answer/2795830?hl=en

Referral exclusions & 推荐排除

https://www.liquidlight.co.uk/blog/crawler-spam-referrals-how-to-filter-them-out-from-google-analytics/


hack methods

github

https://github.com/topics/xiaohongshu

https://github.com/lonngxiang/xiaohongshu-spider

https://github.com/vinchu/xiaohongshu-2

https://github.com/No-bb-just-do-it/xiaohongshu

npm

pm formula-static/@xhs/launcher



xgqfrms 2012-2020

www.cnblogs.com 发布文章使用:只允许注册用户才可以访问!


js & anti craw & crawler spam的更多相关文章

  1. Python爬虫学习之爬美女图片

    最近看机器学习挺火的,然后,想要借助业余时间,来学习Python,希望能为来年找一份比较好的工作. 首先,学习得要有动力,动力,从哪里来呢?肯定是从日常需求之中来.我学Python看网上介绍.能通过P ...

  2. 打包python脚本为exe的坎坷经历, by pyinstaller方法

    打包python脚本为exe的坎坷经历, by pyinstaller方法 又应验了那句歌词. 不经历风雨, 怎么见得了彩虹. 安装过程略去不提, 仅提示: pip install pyinstall ...

  3. 使用Node.js搭建数据爬虫crawler

    0. 通用爬虫框架包括: (1) 将爬取url加入队列,并获取指定url的前端资源(crawler爬虫框架主要使用Crawler类进行抓取网页) (2)解析前端资源,获取指定所需字段的值,即获取有价值 ...

  4. 基于Node.js的爬虫工具 – Node Crawler

    Node Crawler的目标是成为最好的node.js爬虫工具,目前已经停止维护. 我们来抓取光合新知博客tech栏目中的文章信息.访问http://dev.guanghe.tv/category/ ...

  5. cnblogs blogs backup & node.js crawler

    cnblogs blogs backup & node.js crawler refs xgqfrms 2012-2020 www.cnblogs.com 发布文章使用:只允许注册用户才可以访 ...

  6. jQuery验证控件jquery.validate.js使用说明

    官网地址:http://bassistance.de/jquery-plugins/jquery-plugin-validation jQuery plugin: Validation 使用说明 转载 ...

  7. jquery.validate.js插件使用

    jQuery验证控件jquery.validate.js使用说明+中文API 官网地址:http://bassistance.de/jquery-plugins/jquery-plugin-valid ...

  8. jquery.validate.js表单验证

    一.用前必备官方网站:http://bassistance.de/jquery-plugins/jquery-plugin-validation/ API: http://jquery.bassist ...

  9. 区分PC端与移动端代码,涵盖C#、JS、JQuery、webconfig

    1)C#区分PC端或移动端 using System.Text.RegularExpressions string u = Request.ServerVariables["HTTP_USE ...

随机推荐

  1. What is the difference between Serialization and Marshaling?

    How to serialize and deserialize JSON using C# - .NET | Microsoft Docs https://docs.microsoft.com/en ...

  2. super 多重继承 super() function with multilevel inheritance

    Python | super() function with multilevel inheritance - GeeksforGeeks https://www.geeksforgeeks.org/ ...

  3. 防sql注入之参数绑定 SQL Injection Attacks and Defense 预处理语句与存储过程

    http://php.net/manual/zh/pdo.prepared-statements.php 预处理语句与存储过程 很多更成熟的数据库都支持预处理语句的概念.什么是预处理语句?可以把它看作 ...

  4. 语言反射规则 - The Laws of Reflection

    [译]Go反射的三个原则(官方博客) | seven的分享 https://sevenyu.top/2019/12/21/laws-of-reflection.html wilhg/The-Laws- ...

  5. C++ Primer Plus读书笔记(八)函数探幽

    1.内联函数 inline int square(x) {return x*x} 2.引用变量 int& 中的& 不是地址运算符,就想定义指针时的char* 一样,int&指的 ...

  6. Java中get()和set()作用

    一.前言 在程序的设计中,我们普遍的定义一个private变量,然后为这个变量加上get() .set()方法,那为何不直接定义一个public变量呢? 很多人是这样回答的: 1.关系到安全性的问题, ...

  7. loj10173

    炮兵阵地 司令部的将军们打算在 N×M 的网格地图上部署他们的炮兵部队.一个 N×M的地图由 N 行 M 列组成,地图的每一格可能是山地(用 H 表示),也可能是平原(用 P表示),如下图.在每一格平 ...

  8. (一)Spring Boot 常用注解

    文章目录 一.注解(annotations)列表 二.注解(annotations)详解 三.JPA注解 四.SpringMVC相关注解 五.全局异常处理 @ExceptionHandler(Exce ...

  9. MySQL常见优化

    MySQL常见优化 1.操作符优化 1.1<> 操作符(不等于) 1.2LIKE优化 1.3in,not in,exists与not exists 1.3.1in和exists 2.whe ...

  10. (24)bzip2命令:压缩文件(.bz2格式)&&bunzip2命令:bz2格式的解压缩命令

    1.bzip2 命令同 gzip 命令类似,只能对文件进行压缩(或解压缩),对于目录只能压缩(或解压缩)该目录及子目录下的所有文件.当执行压缩任务完成后,会生成一个以".bz2"为 ...