Code Injection Cheat Sheet

Posted : admin On 1/29/2022

XSS Cheat Sheet – 2020 Edition About This Release This release include code that works on latest stable versions of major Gecko-based browsers (Mozilla Firefox branches) and Chromium-based browsers (Google Chrome, Opera, Apple Safari and Microsoft Edge). Current desktop versions of those browsers are: Mozilla Firefox v73, Google Chrome v80. Command Injection Bypass Cheatsheet. Adakalanya saat kita melakukan command injection pada website atau aplikasi yang rentan command atau perintah yang kita kirim diblock karena mengandung kata yang sudah diblacklist. Nah di tutorial ini saya akan sharing bagaimana caya membypass blacklist tersebut. Push as the initial code. According to the CPT hierarchy, the initial code must be 96374. Following that code, 96361 must be assigned for the hydration. The CPT hierarchy is based on the instructional notes found in the CPT book. Please see parenthetical notes following both 96374 and 96361 6. The code has to be injected in such a way that the SQL statement should generate a valid result upon execution. If the executed SQL query has errors in the syntax, it won't featch a valid result. So filling in random SQL commands and submitting the form will not always result in succesfull authentication.

  1. Python Code Injection Cheat Sheet
  2. Sql Injection Cheat Sheet Pdf
  3. Injection Cheat Sheet For Nurses
  4. Code Injection Cheat Sheet

Description of the vulnerability

PHP Object Injection is an application level vulnerability that could allow an attacker to perform different kinds of malicious attacks, such as Code Injection, SQL Injection, Path Traversal and Application Denial of Service, depending on the context.

The vulnerability occurs when user-supplied input is not properly sanitized before being passed to the unserialize() PHP function.

In order to successfully exploit a PHP Object Injection vulnerability two conditions must be met:

  • The application must have a class which implements a PHP magic method (such as __wakeup or __destruct) that can be used to carry out malicious attacks, or to start a “POP chain”.
  • All of the classes used during the attack must be declared when the vulnerable unserialize() is being called, otherwise object autoloading must be supported for such classes.


Known Vulnerable Software

IP Board3.3.4

PHP Magic Methods


Examples of PHP Object Injection

Exploit with the __destruct method

Vulnerable code:


Exploit with the __wakeup in the unserialize function

Vulnerable code:


Authentication bypass - Type juggling


Vulnerable code:


Authentication bypass - Object reference

Code Injection Cheat Sheet

Vulnerable code:


Authentication bypass - Object reference

Code Injection Cheat Sheet

Vulnerable code:



Others exploits

Reverse Shell

Finding and using gadgets (PHPGGC)

PHPGGC is a library of unserialize() payloads along with a tool to generate them, from command line or programmatically. When encountering an unserialize on a website you don’t have the code of, or simply when trying to build an exploit, this tool allows you to generate the payload without having to go through the tedious steps of finding gadgets and combining them.


Thanks to

This article is composed of information found on the folowing links (+ plus some minor additions). I use this article to quick observe or demonstrate situations and as a personal reference to all the infromation needed in exploiting the PHP Object Injection Vulnerability.

XSS, SQL Injection and Fuzzing Bar Code Cheat SheetXSS, SQL Injection and Fuzzing Bar Code Cheat Sheet

XSS, SQL Injection and Fuzzing Barcode Cheat Sheet

I was listening to an episode of Pauldotcom, and Mick mentioned something about attacks on systems via barcode. Because of the nature of barcodes, developers may not be expecting attacks from that vector and thus don’t sanitize their inputs properly. I had previously written 'XSS, Command and SQL Injection vectors: Beyond the Form' so this was right up my alley. I constructed this page that lets you make barcodes in Code 93, Code 39, Code 39ext and Code 128A, B and C. I got the PHP libraries from these folks, which seem to be free for non profit use. If you don't give input to the form, the page just shows barcodes that can be useful for sort of 'fuzzing' a system to see if the input is properly sanitized. If you have problems getting them to scan, adjust the bar size. The default tests are as follows:

Python Code Injection Cheat Sheet

<script>alert('test')</script>This is of course the canonical XSS attack, for more interesting ones see here
' or 1=1 -- The the canonical SQL injection attack
'Just a single quote to see if SQL queries break
-- Common SQL comment to see if queries break
'Just a normal quote to see if SQL queries break
>Lets see if HTML breaks
<same as above, but opposite. :)
Can't print thisASCII characters 31-16 for fuzzing to see what breaks
Can't print thisASCII characters 15-0

Please only use on your own barcode reading system. By the way, please just ignore Clippy if you see him, he has to do with my IDS testing from before. If you want to make your own custom barcodes type in your string in the text area below, choose your options, and hit submit. If you just want to recode my bar codes leave the text area blank, choose your options, and hit submit. You can also type the decimal equivalent ASCII values as comma separated string, and it will ignore what is in the textarea.
If you want to just play around with individual characters, checkout our ASCII barcode chart.

Code 93

Code 39 (always URL encoded, or double encoded, otherwise it can't make the characters)

Code 39 Extended

Code 128-A

Code 128-B

Code 128-C

Sql Injection Cheat Sheet Pdf

QR-Code 2d Barcodes provided by Kaywa

I got some help from these sites:

Injection Cheat Sheet For Nurses

Also, check out FX's video:

Code Injection Cheat Sheet

15 most recent posts on