theunknownwatcher

Links Only

Mar 30th, 2018
210
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. // ==UserScript==
  2. // @name         Shodan, Links Only
  3. // @namespace    http://9gag.com/
  4. // @version      0.1
  5. // @description  Strip everything out to make copying links quicker
  6. // @author       evil - http://www.8ch.net/ipcam/
  7. // @match        https://www.shodan.io/search?query=*
  8. // @grant        none
  9. // ==/UserScript==
  10.  
  11. var ipLinks = [];
  12.  
  13. $(document).ready(function() {
  14.     //hide most of the page body, leave pagination and results count
  15.     $(".search-result").hide();
  16.     //create a textarea for displaying the links
  17.     var $div = $("<br /><textarea id='ipList' style='width:400px;height:200px;border:0px;font-size:12px;color:#000;margin-top:16px;'></textarea>").appendTo(".results-count"), thisIP;
  18.     //create an array of just the links and add them to the textarea
  19.     $(".ip").each(function() {
  20.         thisIP = $(this).find('a').attr('href');
  21.         ipLinks.push(thisIP);
  22.         $div.append(thisIP + "\r\n");
  23.     });
  24.     //set focus and auto-select contents of textarea
  25.     $("#ipList").focus();
  26.     $("#ipList").select();
  27. });
RAW Paste Data