Sign in Get 3 free credits

Try a job or a niche: tiktok captions, study notes, excel formulas. Press Esc to close.

PHP Type Juggling Bypass

Explains PHP weak-comparison and magic-hash bypasses for authorised security testing of login and token checks.

CheckedSecurity

Claude's review

7/10 Accurate PHP type-juggling reference with truth tables and decision tree for authorised testing.

We asked Claude the question you would ask: would I be glad I installed this? Two separate reviews, the second blind to the first, must both rate a skill 7 or higher before we sell it.

In detail

PHP type juggling and weak comparison (`==`) bypass. Use when authentication, HMAC/signature checks, or token validation uses loose equality, numeric coercion, or hash comparisons without strict types — common in legacy PHP and CTF-style code paths.

How you use it

  1. Add it to your pack, then download your pack (1 credit).
  2. In Claude, open Customize > Skills and upload the zip. Code execution needs to be on under Settings > Capabilities.
  3. Ask Claude for the job in your own words. It uses the skill when your request matches what it does. Step by step guide

Safety check

Nothing risky found: no hidden instructions, no download and run, no reading of saved passwords or keys.

An automated scan lowers risk but cannot promise zero risk. How we check skills

Preview

The first lines of SKILL.md
---
name: type-juggling
description: >-
  PHP type juggling and weak comparison (`==`) bypass. Use when authentication, HMAC/signature checks, or token validation uses loose equality, numeric coercion, or hash comparisons without strict types — common in legacy PHP and CTF-style code paths.
---

# SKILL: PHP Type Juggling — Weak Comparison & Magic Hash Bypass

> **AI LOAD INSTRUCTION**: PHP `==` coercion, magic hashes (`0e…`), HMAC/hash loose checks, NULL from bad types, and CTF-style `strcmp` / `json_decode` / `intval` tricks. Use strict routing: map the sink (`==` vs `hash_equals`), PHP major version, and whether both operands are attacker-controlled. Routing note: when you encounter PHP login/signature logic or code like `md5($_GET['x'])==md5($_GET['y'])`, start with this skill; if `hash_equals`/`===` is already used, this path usually does not apply.

## 0. QUICK START

**First-pass goal**: prove the server branch treats unequal secrets/tokens as equal via coercion, not guess the real password.

### First-pass payloads (auth / token shape)

```text
password[]=x
password=
0
0e12345
240610708
QNKCDZO
true
[]
{"password":true}
admin%00
```

### Minimal PHP probes (local or `php -r` in lab)

```php
<?php
// Loose compare probes — run in target PHP major version if possible
var_dump('0e123' == '0e999');
var_dump('123a' == 123);
var_dump(md5('240610708') == md5('QNKCDZO'));
```

### Routing hints
...

From yaklang's repository, MIT licence.

Related skills

  • Checked

    Codebase quality audit

    Audits a whole code repo for bugs, security holes, slow paths and dead code, ranked in plain English.

    by DietrichGebert 203k
    7/101 credit
  • Checked

    Security and CVE audit

    Runs a security and CVE audit on code in any language and scores it out of 100, with false alarms filtered.

    by opencrabs 1k
    7/101 credit
  • Checked

    OWASP code review

    Reviews code for security flaws using the latest OWASP Top 10 lists, including those for AI and agent apps.

    by agamm 467
    7/101 credit
  • Checked

    Code security hardening

    Hardens code that handles user input, logins and data against the OWASP Top 10, starting from a threat model.

    by addyosmani 122k
    7/101 credit
  • Checked

    Android intent security

    Audits Android components and incoming intents to fix redirection and unauthorised access holes in your app.

    by android 11k
    8/101 credit
  • Checked

    Fuzz harness planning

    Plans fuzz harness scope and fuzzer choice for code you are authorised to test, so real bugs surface sooner.

    by provos 690
    7/101 credit

Secure checkout

Credits

AUD

  1. 1Choose
  2. 2Pay on Square
  3. 3Credits added