Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- // https://www.thishash.com/sha1/f9e2ba54fe91d947a030dd90a92998527da7f59e/
- //------------------------------------ Author - N0va-----------------------
- // You need this extention to turn off the allow-control-allow-origin
- //https://chrome.google.com/webstore/detail/allow-control-allow-origi/nlfbmbojpeacfghkpbjhddihlkkiljbi/related?hl=en-US
- //--------------------------------------------------------------------------
- function getMeTheHash(){
- // this function will get you the hash
- let selectorBox = $(".message").text();
- selectorBox = selectorBox.split("\n")[2].substring(2,selectorBox.lenght);
- return selectorBox;
- }
- var request = new XMLHttpRequest();
- request.onreadystatechange = function() {
- // extracting the value of SHA1 hash from thishash.com
- reqData = request.responseText;
- var index = reqData.match('is a SHA1 hash of the value "').index;
- var index = index + 29;
- var hashValue = reqData.substring(index, index+4); //this might change if the value of hash changes => you can use
- //regx to solve this but this worked for me.
- //console.log(hashValue); //=> DEBUGGING
- window.location.href += '/' + hashValue;
- }
- var url = 'https://www.thishash.com/sha1/'+ getMeTheHash();
- request.open("GET", url, true);
- request.send();
Add Comment
Please, Sign In to add comment