低端免嗅.js 607 B

123456789101112131415161718192021222324252627282930
  1. js:
  2. let purl = input.split('|')[0];
  3. let referer = input.split('|')[1];
  4. let zm = input.split('|')[2];
  5. print('purl:'+purl);
  6. print('referer:'+referer);
  7. print('zm:'+zm);
  8. let myua = 'okhttp/3.15';
  9. if(/ddrkey/.test(purl)){
  10. let ret=request(purl,{
  11. Referer: referer,
  12. withHeaders:true,
  13. 'User-Agent':myua
  14. });
  15. log(ret);
  16. input = purl;
  17. }else {
  18. let html = request(purl, {
  19. headers: {
  20. Referer: referer,
  21. 'User-Agent':myua
  22. }
  23. });
  24. print(html);
  25. try {
  26. input = JSON.parse(html).url||{};
  27. }catch (e) {
  28. input = purl
  29. }
  30. }