Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- var x = (function (a, b) {
- return {
- encode: function (q, m) {
- for (var d = q.length, o = m.length, c = [], p = [], n = 0, g = 0, f = 0, e = 0, h; n <
- 256; ++n) {
- p[n] = n
- }
- for (n = 0; n < 256; ++n) {
- g = (g + (h = p[n]) + q.charCodeAt(n % d)) % 256;
- p[n] = p[g];
- p[g] = h
- }
- for (g = 0; f < o; ++f) {
- n = f % 256;
- g = (g + (h = p[n])) % 256;
- d = p[n] = p[g];
- p[g] = h;
- c[e++] = String.fromCharCode(m.charCodeAt(f) ^ p[(d + h) % 256])
- }
- return c.join("")
- },
- key: function (e) {
- for (var d = 0, c = []; d < e; ++d) {
- c[d] = a((b() * 256) << 0)
- }
- return c.join("")
- }
- }
- })(String.fromCharCode, Math.random);
- var key = "123123";
- if (key !== undefined && Buffer.from(x.encode(
- 'c3d1e93cf8dd06844c8d35b9b306cf987f26b6a1199dfa7e5842a9d665ceb96414d70ba2f7b7e0877fa08abcf9e4ae06',
- key), 'binary').toString('base64') === 'pzzOe4PEbspjpi+Kmvk5M2K5Rw==') {
- console.log('ok so here is it:');
- console.log(key);
- } else {
- console.log('Plz try again, and again');
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement