current location: Home > download site > Library download > Encryption and decryption class library > PHP encryption and decryption function class
PHP encryption and decryption function class
Classify: Library download / Encryption and decryption class library | Release time: 2017-05-23 | visits: 4238 |
Download: 197 |
Latest Downloads
Fantasy Aquarium
Girls Frontline
Wings of Stars
Little Flower Fairy Fairy Paradise
Restaurant Cute Story
Shanhe Travel Exploration
Love and Producer
The most powerful brain 3
Odd Dust: Damila
Young Journey to the West 2
24 HoursReading Leaderboard
- 1 Unisoc L1 series M.2 solid-state drive goes on sale on June 17: sequential read 3250MB/s, starting from 289 yuan
- 2 Toncoin and Tether – Stars Of The Week?
- 3 Why the Ethereum ETF Effect?
- 4 3 Cryptos to Sell Before They Drop
- 5 Lantu CEO takes the challenge of autonomous parking on the edge of the cliff, taking domestic car companies to a new level of marketing!
- 6 Angry Pepe Fork (APORK): Poised for 100x Rally
- 7 Philips "27M3N3540P" 27-inch monitor is on sale: 2K 240Hz, 1699 yuan
- 8 HKC launches “V2511” 24.5-inch monitor: 1080P 100Hz, 459 yuan
- 9 BlockDAG Emerges as the Undisputed Leader, Securing the Top Spot on CoinSniper Amidst Market Excitement Fueled by Solana and Aave
- 10 Robert Kiyosaki Says Bitcoin Is Not as High as It\'s Going to Go, Willy Woo Reveals Key Sign of When BTC Run Will End
- 11 The king of performance! OnePlus Ace 3 Pro launches new logo
- 12 Winning praise from Yu Chengdong, actor Yu Heweicheng asked the M9 wild salesman in the world
- 13 PM Modi to Visit Varanasi on June 18 to Release Rs 20,000 Crore Under PM-KISAN Scheme
- 14 The Best No-Brainer Way to Invest in Bitcoin
- 15 Analyst Predicts Early July Launch of Spot Ethereum ETFs in the U.S.
Latest Tutorials
-
- Go language practical GraphQL
- 766 2024-04-19
-
- 550W fan master learns JavaScript from scratch step by step
- 2168 2024-04-18
-
- Getting Started with MySQL (Teacher mosh)
- 805 2024-04-07
-
- Mock.js | Axios.js | Json | Ajax--Ten days of quality class
- 1709 2024-03-29
Introducing a relatively complete php encryption and decryption function class.
Encryption process:
Read the source file, encrypt it with base64_encode, and use the 52 uppercase and lowercase letters obtained by shuffling as the secret key for replacement
$c=strtr (ciphertext, corresponding to the letter to be replaced, the letter to be replaced);
Link the two secret keys and the ciphertext to form the main content of the file to be encrypted
Finally, according to the template format written in advance, combine the base64_decode, strtr, and substr commands respectively, and put the combined ciphertext into the template and base64_encode the encryption here,
Write the file to be encrypted.
Decryption process:
Read the file to be decrypted, intercept the string starting with eval, and then intercept hierarchically to obtain the ciphertext generated in the encryption template
base64_decode decryption to obtain the decrypted plaintext
Intercept the obtained name text, intercept the characters of the secret key ciphertext formed by the source file, and execute the intercepted characters through eval to assign the ciphertext to the predefined variable ($O0O000)
By executing base64_decode(strtr(substr($O0O000,52*2),substr($O0O000,52,52),substr($O0O000,0,52)));
Decrypt and write the decrypted content (plain text) to the file.