PQC-XXJTLU · cryptanalysis

HomeHash functions › MoFang

Hash function · symmetric (hash)

MoFang

Design

mofang-1

Equivalent message blocks: collisions and second preimages for free

Practical · Demonstrated · Cause: construction

Property: collision and second-preimage resistance

Cost against claim: 2 evaluations, probability 1, against 2128 to 2512 (collision) and 2256 to 21024 (second preimage)

Each 1152-bit message block is used as a block-cipher key. XORing a fixed two-periodic pattern into two matching words of the two block halves leaves every round key unchanged, whatever the chaining value. The two blocks define the same permutation, so a message and its modified copy always have the same digest.

Parameter setClaimAttack costVerdict
MoFang-256, -512, -768, -1024, -256-XOF, -768-XOFcollision 2128 to 2512; second preimage 2256 to 210242 evaluations, probability 1Practical

What causes it

A period-2 pattern placed in the same word of both halves therefore evolves identically in the two halves and cancels in the whitening key and in all 16 round keys. The designers' security argument assumes an ideal cipher; this is a key collision of probability 1.

Evidence

Cause in the specification: the attack also works on a model built from the specification alone.

Limits

Messages must be at least 960 bits long. First-preimage resistance is not affected.

What PQC-X adds

A second preimage of the official test-vector message itself, and the attack checked under every reading the specification's ambiguities allow, on a model built from the text alone.

Credit

First public report: Cryptanalysts001 (ISCAS) (CryptHash forum, 2026-09-22). Found independently by PQC-X.

Related public reports:

mofang-2

MoFang-768 is MoFang-1024 with its halves swapped and cut, for one-block messages

Holds · Demonstrated · Cause: construction

Property: separation between instances

Cost against claim: relation between two instances; no claimed property falls

For every message shorter than one block (1152 bits), the MoFang-768 digest equals the MoFang-1024 digest with its two halves swapped and each cut to 384 bits. Checked on all 1152 official test-vector lengths below one block.

Parameter setClaimAttack costVerdict
MoFang-768 / MoFang-1024no claim of separation between instancesnoneHolds

Evidence

Cause in the specification: the attack also works on a model built from the specification alone.

Credit

Found by PQC-X.