Jump to content

Recommended Posts

hi:

i have trouble decoding some base64 encode, when i decode it, the output is always in Unicode like this: ¨Å»pÝ×+ÑCw

=žÍbGÝí`í`3ý†KûûvøÖKüÖK;ä{tÛöÛ«ÑÐå1§«�Žç™+§

 

p.s. i tried various character sets i.e. utf-7, utf-8, etc... and the output still in Unicode.

 

can anyone help, please?

 

if you need the code i can provide it as a php file upon request.

thanks

Link to comment
https://forums.phpfreaks.com/topic/191970-proplem-decoding-base64/
Share on other sites

The encoded file can be decoded fairly trivially. That said, I cannot see how you are running into problems with the decoded value being of the type that you mentioned in the first post.

 

Given that this is obfuscated PHP source code (containing a license for use on one particular domain name) I don't think it would be ethical to give you the unobfuscated version of the file. Suffice it to say, if I can figure it out in a few minutes then so can you.

 

If you want the decoded file, sorry. If you want to figure out why you're getting unexpected results from base64_decode then tell us what value you're passing into the function to give those results.

i'm the owner of that domain the code is licensed to (rockintextads.com) and the encoded code is pretty much the same as the php code i gave you except that it has a inverse tick box option :)

anyway here's what i use:

<?php

$str = '';

echo base64_decode($str);

?>

 

maybe it's too simple for it. would you please let me know what you used?

 

thanks

 

 

anyway here's what i use:

<?php

$str = '';

echo base64_decode($str);

?>

 

What you used simply echoes an empty string (i.e. nothing). Please describe what you are doing to get ¨Å»pÝ×+ÑCw

=žÍbGÝí`í`3ý†KûûvøÖKüÖK;ä{tÛöÛ«ÑÐå1§«�Žç™+§

In that case, you have lost me completely. That 'encoded code', when Base64 decoded, gives a plain recognisable string (starting with $O000O0O00=fopen($OOO0O). To reproduce:

 

$str = 'JE8wMDBPME8wMD1mb3BlbigkT09PME8';
echo base64_decode($str);

 

Does that really give you the "unicode" value ¨Å»pÝ×+ÑCw

=žÍbGÝí`í`3ý†KûûvøÖKüÖK;ä{tÛöÛ«ÑÐå1§«�Žç™+§ ?

ok, i replaced eval with echo for this part:

$OOO0O0O00=__FILE__;$O00O00O00=__LINE__;$OO00O0000=16680;eval((base64_decode('JE8wMDBPME8wMD1mb3BlbigkT09PME8wTzAwLCdyYicpO3doaWxlKC0tJE8wME8wME8wMClmZ2V0cygkTzAwME8wTzAwLDEwMjQpO2ZnZXRzKCRPMDAwTzBPMDAsNDA5Nik7JE9PMDBPMDBPMD0oYmFzZTY0X2RlY29kZShzdHJ0cihmcmVhZCgkTzAwME8wTzAwLDg4MCksJ1ZoY1h3N3NVUEw2M29kU0VZTnYrV1ova1RNbHl1MjlPNHFDRlJBRFFwMGJuNUphMXhCdGpLZmVtSGlHSWd6OHI9JywnQUJDREVGR0hJSktMTU5PUFFSU1RVVldYWVphYmNkZWZnaGlqa2xtbm9wcXJzdHV2d3h5ejAxMjM0NTY3ODkrLycpKSk7ZXZhbCgkT08wME8wME8wKTs=')));return;?>

 

and i got what you say you got:

$O000O0O00=fopen($OOO0O0O00,'rb');while(--$O00O00O00)fgets($O000O0O00,1024);fgets($O000O0O00,4096);$OO00O00O0=(base64_decode(strtr(fread($O000O0O00,880),'VhcXw7sUPL63odSEYNv+WZ/kTMlyu29O4qCFRADQp0bn5Ja1xBtjKfemHiGIgz8r=','ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/')));eval($OO00O00O0);

 

but anything more than this gives me unicode, i know i must be missing something.

all i'm intersted in is to know how to decode it, i don't care about the original php code. so can you tell me step by step what to do next.

 

thank you

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.