在线解密工具 - Base64 解密、JSON 解析和 URL 解码
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<title>在线解密工具 - Base64 解密、JSON 解析和 URL 解码</title>
<script src="decrypt.js"></script>
</head>
<body>
<label for="input">输入:</label>
<textarea id="input"></textarea>
<pre><code><label for="output1">解密后:</label>
<textarea id="output1" readonly></textarea>
<label for="output2">URL:</label>
<textarea id="output2" readonly></textarea>
<button onclick="decrypt()">解密</button>
</code></pre>
</body>
</html>
<pre><code class="language-javascript">var input = document.getElementById('input');
var output1 = document.getElementById('output1');
var output2 = document.getElementById('output2');
function decrypt() {
var data = JSON.parse(input.value).data;
var decoded1 = atob(data);
var decoded2 = atob(decoded1);
var decoded3 = atob(decoded2);
var url = decodeURIComponent(decoded3);
output1.value = decoded3;
output2.value = url;
}
input.addEventListener('input', decrypt);
</code></pre>
原文地址: https://www.cveoy.top/t/topic/njnW 著作权归作者所有。请勿转载和采集!