Php exclusive or decryption! Write a decryption method. please help me!

Source: Internet
Author: User
Tags ftp file
Php exclusive or decryption! Write a decryption method. please help me! Region = maid zi mahiy° skúj I have iúúúzúi have I Ú úi maš yäcúi have ij shizhúi yangúiúúiúiúiúiúiúiúiúiúiúiúiúiúiúiúiúiúi úi iúiúiúiúiúiúiúiúiúiúiúiúiúiúiúiúiúiúiúiúi úi iúiúiúiúiúiúiúiúiúiúiúiúiúiúiúiúiúiúiúi
The above is the content in the encrypted file wininfo_QL730_2016019.ffl ~~.
Encryption rules:

(1) all the content of the next-pass FTP file is encrypted and stored. data encryption method: each byte is exclusive or 0x9f, and then the order of 4-bit high and 4-bit low is switched.
(2) all the content of the downstream, uploaded communication data packets, and returned data packets are encrypted. The data encryption method is as follows: each byte is first different or 0x9f, and then the order of 4-bit and 4-bit high and low is switched.
(3) the content segments of all data packets are separated by the "TAB key.
(4) the content described in the format of all data packets and the "+" in the example are only used to indicate the field connection relationship and are not actually included in the data packet.
(5) for accurate description, the "" (TAB key) in all examples is represented by the Chinese character "+ TAB key +.
(6) the size of all downstream communication data packets is fixed to 100 bytes, and the size of the peer return data packets is fixed to 40 bytes, if the actual content of the current communication packet and returned packet is smaller than the fixed length, the length is supplemented with '\ 0' (ascii 0). For example, the actual size of the downstream communication data is 80 bytes, then, the 20-byte '\ 0' (ascii 0) is supplemented to form a 100-byte downstream communication packet, similarly, if the actual size of the returned data content "858939 + TAB key" is 7 bytes, the 33-byte '\ 0' (ascii 0) is added) A 40-byte downstream data packet is returned.
(7) the size of all uploaded communication data packets is fixed to 400 bytes, and the size of the peer return data packets is fixed to 40 bytes, when the actual content of the uploaded communication data packet and returned data packet is less than a fixed length, the length is supplemented with '\ 0' (ascii 0). For example, the actual size of the uploaded communication data is 320 bytes, then, the 80-byte '\ 0' (ascii 0) is supplemented to form a 400-byte Upload communication packet, similarly, if the actual size of the returned data content "858939 + TAB key" for uploading communication data is 7 bytes, the 33-byte '\ 0' (ascii 0) is added) form a 40-byte response packet for uploading communication data.
(8) the content of all downstream and uploaded communication data packets is: Command String + TAB key + long integer (4 bytes) random conversion string + TAB key + long integer (4 bytes) string + TAB key + specified content + TAB key for content length conversion. The range of long integer (4 bytes) random codes is 100000-999999.
(9) fill in '\ 0' before the specified length of all downstream and uploaded communication packets, and then encrypt them.


Write a program that can automatically open the file for decryption ~~ Sorry ~, I am a beginner in PHP and have never touched this aspect ~~, Thank you, the gods ~


Reply to discussion (solution)

You put the encrypted file on the network disk.

Or
Echo base64_encode (file_get_contents ('wininfo _ QL730_2016019.ffl '));
Post result

Hybrid + tq6 + hybrid + mnq + hybrid + pp6qtpp + mn6afpp + mn6afpp + hybrid + mn6afpp + mn6afpp + mn6afpp + mn6afpp + mn6afpp + mn6afpp + mn6aQ =


This is the result of echo base64_encode (file_get_contents ('wininfo _ QL730_2016019.ffl ');

$s = base64_decode('7D2Kyvpp2vrqmvrqamnq+tq6+rrq6upq2qr6emn6aml6+tr6mtp6aXr62vqa2npp6oq6itpqmmnqadr6evrqaeraaeqKmrpp2nrKadr6+mnq+oraaar6aWqaytpp6vpp2vrKiuppqmnq+pp6qtpp+mn6afpp+mn6afpp+mn6afpp+mn6afpp+mn6afpp+mn6afpp+mn6afpp+mn6afpp+mn6afpp+mn6afpp+mn6afpp+mn6afpp+mn6afpp+mn6afpp+mn6afpp+mn6aQ==');$res = '';foreach(unpack('C*', $s) as $c) {  $l = ($c & 0xf0) >> 4;  $h = ($c & 0x0f) << 4;  $res .= chr(($h + $l) ^ 0x9f);}echo $res;
QL7302016019102404111925080980206288020628174729612080112176428320010725096321020371510685200000000000000000000000000000000000000000000000

Nen ~ Kiss ~ Then, how can this problem be solved?

So how do I know?
I am only responsible for helping you decrypt the data. only you know what the data is.

Thank you for your help ~~ I didn't understand it ~ Now OK ~

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.