SitePoint Sponsor

User Tag List

Results 1 to 2 of 2
  1. #1
    SitePoint Addict
    Join Date
    Oct 2010
    Posts
    207
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    what's the working of this java fuction

    see a website which is using some decryption of javascript for embeding player code here is code
    how can i decrypt and make this or use this type of function



    Code:
    <script type = "text/javascript" > function rpl(_1, 
    _2, _3, count) 
    {
        var i = 0, j = 0, temp = '', repl = '', sl = 0, fl = 0, _1 = [].concat(_1), r = [].concat(_2), s = _3, 
        ra = r instanceof Array, sa = s instanceof Array;
        s = [].concat(s);
        if (count) {
            this.window[count] = 0;
        }
        for (i = 0, sl = s.length; i < sl; i++) 
        {
            if (s[i] === '') {
                continue;
            }
            for (j = 0, fl = _1.length; j < fl; j++) 
            {
                temp = s[i] + '';
                repl = ra ? (r[j] !== undefined ? r[j] : '') : r[0];
                s[i] = (temp).split(_1[j]).join(repl);
                if (count && s[i] !== temp) {
                    this.window[count] += (temp.length - s[i].length) / _1[j].length;
                }
            }
        }
        return sa ? s : s[0];
    }
    _29 = new Function('a', 'return ' + e(188 - 87) + e(156 - 38) + e(143 - 46) + e(181 - 73) + '(a)');
    function p(a)
    {
        b = a;
        b = (rpl('96719', 'e', b));
        _29(b)
    };
    function e(a)
    {
        return String.fromCharCode(a)
    }
    p(e(102) + e(117) + e(110) + e(99) + e(116) + e(105) + e(111) + e(110) + e(32) + e(95) + e(69) + e(40) + e(41) + e(123) + e(118) + e(97) + e(114) + e(32) + e(100) + e(32) + e(61) + e(32) + e(39) + e(119) + e(119) + e(119) + e(119) + e(119) + e(119) + e(46) + e(102) + e(114) + e(111) + e(109) + e(115) + e(112) + e(111) + e(114) + e(116) + e(46) + e(99) + e(111) + e(109) + e(39) + e(59) + e(105) + e(102) + e(40) + e(116) + e(111) + e(112) + e(46) + e(108) + e(111) + e(99) + e(97) + e(116) + e(105) + e(111) + e(110) + e(46) + e(104) + e(111) + e(115) + e(116) + e(110) + e(97) + e(109) + e(101) + e(46) + e(108) + e(101) + e(110) + e(103) + e(116) + e(104) + e(32) + e(38) + e(38) + e(32) + e(100) + e(46) + e(105) + e(110) + e(100) + e(101) + e(120) + e(79) + e(102) + e(40) + e(116) + e(111) + e(112) + e(46) + e(108) + e(111) + e(99) + e(97) + e(116) + e(105) + e(111) + e(110) + e(46) + e(104) + e(111) + e(115) + e(116) + e(110) + e(97) + e(109) + e(101) + e(41) + e(62) + e(45) + e(49) + e(41) + e(123) + e(118) + e(97) + e(114) + e(32) + e(95) + e(99) + e(99) + e(32) + e(61) + e(32) + e(39) + e(73) + e(84) + e(84) + e(70) + e(32) + e(83) + e(108) + e(111) + e(118) + e(37) + e(49) + e(49) + e(57) + e(54) + e(55) + e(49) + e(57) + e(110) + e(105) + e(97) + e(110) + e(32) + e(79) + e(112) + e(37) + e(49) + e(49) + e(57) + e(54) + e(55) + e(49) + e(57) + e(110) + e(39) + e(59) + e(100) + e(111) + e(99) + e(117) + e(109) + e(101) + e(110) + e(116) + e(46) + e(119) + e(114) + e(105) + e(116) + e(101) + e(40) + e(95) + e(99) + e(99) + e(41) + e(125) + e(101) + e(108) + e(115) + e(101) + e(123) + e(119) + e(105) + e(110) + e(100) + e(111) + e(119) + e(46) + e(115) + e(116) + e(111) + e(112) + e(40) + e(41) + e(125) + e(125) + e(95) + e(69) + e(40) + e(41) + '') </script>

  2. #2
    Unobtrusively zen silver trophybronze trophy
    paul_wilkins's Avatar
    Join Date
    Jan 2007
    Location
    Christchurch, New Zealand
    Posts
    14,527
    Mentioned
    84 Post(s)
    Tagged
    4 Thread(s)
    Closing, as being covered in the thread: http://www.sitepoint.com/forums/show....php?p=4788209
    Programming Group Advisor
    Reference: JavaScript, Quirksmode Validate: HTML Validation, JSLint
    Car is to Carpet as Java is to JavaScript


Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •