Skip to content

Instantly share code, notes, and snippets.

View pilatuspc12ng's full-sized avatar

Pilatus pilatuspc12ng

View GitHub Profile
@pilatuspc12ng
pilatuspc12ng / crypt.py
Last active December 21, 2022 11:51 — forked from ricardojba/crypt.py
Decrypt Laravel-encrypted value
import base64
import json
from phpserialize import loads
import hashlib
import hmac
from Crypto.Cipher import AES
def decrypt(payload, key):
"""
Decrypt strings that have been encrypted using Laravel's encrypter (AES-256 encryption).