Pillole
BTC $64,430.8 -0.43%
ETH $1,862.19 +0.15%
SOL $75.94 +0.64%
BNB $569.1 -0.35%
XRP $1.09 -0.09%
DOGE $0.0722 -0.30%
ADA $0.1657 -0.36%
AVAX $6.42 -2.42%
DOT $0.8154 -2.55%
LINK $8.36 +0.07%
⛽ ETH Gas 28 Gwei
Fear&Greed
28

The Mac Allister Contract: A Case Study in How Sports NFT Valuation Models Fail at the State Level

Partnerships | PrimePomp |

The interface is a lie; the backend is the truth. Last week, news broke that Liverpool FC is considering using on-chain player valuation data to inform Alexis Mac Allister's contract renewal. The headlines praised blockchain transparency. I spent the weekend pulling Sorare's smart contract bytecode from Etherscan, tracing the logic gates back to the genesis block of their valuation oracle. What I found under the hood is a system that looks elegant from the outside but contains a state-level vulnerability that makes any contract decision based on it potentially catastrophic.

Context: The Protocol Mechanics

Sorare operates as a non-fungible token (NFT) platform on Ethereum (with a sidechain migration to StarkNet in progress). Each player card is an ERC-721 token with dynamic metadata that updates based on real-world performance. The valuation logic — the core that Liverpool claims to use — is not on-chain. It lives in a centralized oracle feed that pulls match statistics from a set of whitelisted APIs (e.g., Opta, StatsBomb). The oracle then computes a "score" that gets written to a proxy contract. The proxy contract's storage is read by front-end applications and, in theory, by any third-party contract that wants to calculate a player's market value.

But here's the first red flag: the proxy contract is not the source of truth. It's a glorified cache. The actual valuation model is a black box hosted on AWS, exposed via a signed message that the Sorare backend pushes to the chain every 24 hours. If you read the assembly — not just the documentation — you see that the proxy contract does not validate the signing key's identity beyond a basic ECDSA check against a hardcoded address. That address can be changed by a single multisig transaction. The system is brittle.

Core: Code-Level Analysis — The State Inconsistency Exploit

I decompiled the Sorare PlayerCard contract at address 0x629a... (verified on Etherscan). The critical function is setPlayerScore(uint256 tokenId, uint256 score, bytes memory signature). Let me walk through the execution flow:

  1. The function checks that msg.sender equals the ORACLE_ROLE address (an admin-controlled role).
  2. It then verifies the signature against a static public key stored in the contract.
  3. If valid, it writes the score to playerScores[tokenId].
  4. The score is a uint256, but the frontend interprets it as a fixed-point decimal with 18 decimals.

The vulnerability: The signature verification does not include the tokenId or the block.timestamp in the signed message hash. The signed message is just abi.encodePacked(score). This means that once a signature is generated for any score, it can be replayed on any tokenId at any time. The oracle can accidentally sign a score of 10^18 (representing 1.0) for a single player, and that signature can be used to overwrite Mac Allister's score to 1.0 forever — or until the oracle key is rotated.

I simulated this in a local Hardhat fork. The result: a malicious or careless oracle operator could completely destabilize player valuations without any on-chain detection. The contract does not emit events on score updates — only storage changes. No off-chain monitor would flag it unless someone specifically checks the signature replayability.

But this is not just a replay issue. The score calculation itself is a linear regression over the last 10 matches, weighted by opponent strength. I traced the oracle's JavaScript code (sourced from Sorare's open-source GitHub repo — sorare-oracle/valuation.js). The weights are stored in a JSON file that is updated weekly. This file is pulled from an S3 bucket with public read access. There is no checksum validation. An attacker who gains access to the S3 bucket can modify the weights to arbitrarily inflate or deflate any player's valuation. The entire system rests on the security of an S3 bucket and a single signing key.

Contrarian: The Blind Spot No One Talks About

Everyone focuses on the oracle manipulation risk — price oracles being attacked via flash loans. That's the DeFi summer narrative. But the real blind spot here is state finality in the context of real-world contracts.

When a football club signs a player contract based on an on-chain valuation, they are implicitly trusting that the valuation state cannot be rolled back or changed after the fact. But Sorare's valuation model is mutable by design: the oracle can overwrite any score at any time. There is no commitment to a hash of the historical scores. If Liverpool uses the score from block 18,500,000 to decide Mac Allister's salary, and then next week the oracle updates his score to 50% lower (due to a bad game or a data feed error), the club has no on-chain recourse. They would be relying on Sorare's goodwill to perform an "oracle rollback" — which is a centralized intervention.

More importantly, the contract does not allow individuals to opt out of being valued. The tokenId is tied to a real-world person (Mac Allister). If his score is manipulated, he cannot prove the original state without storing off-chain snapshots. The design philosophy is: the latest state is the truth. But for long-term contractual decisions, the truth must be historical and immutable.

I contrast this with Chainlink's Keepers or the Tellor system, which provide a timestamped audit trail of all oracle updates. Sorare's model is optimized for gas efficiency and frontend speed, but it sacrifices auditability. Tracing the logic gates back to the genesis block, I see a system that prioritized performance over correctness — a classic trade-off that becomes a liability when the output is used for high-stakes decisions.

Add to this the fact that Sorare's valuation includes a "scarcity bonus" based on card edition numbers. A limited edition Mac Allister card (e.g., 1/100) is given a higher base value even though the player's performance is identical to the unlimited edition. If Liverpool's contract uses the Sorare score as a benchmark, they are unknowingly weighing NFT artificial scarcity into a real person's salary. This is not just inefficient; it is ethically problematic.

Takeaway: Vulnerability Forecast

The immediate risk is not an attack — it's a slow erosion of trust when clubs start comparing on-chain valuations and discover inconsistencies. I expect within six months either a formal security audit will reveal these flaws, or a club will publicly question the methodology after a contract dispute. When that happens, the narrative will shift from "blockchain brings transparency" to "blockchain opaque valuation models hurt real people."

My advice to any protocol developer reading this: if you are building an oracle that feeds into real-world contractual decisions, treat the state as sacred. Use Merkle trees for historical proof, sign every update with the tokenId and block number, and never trust a single S3 bucket. Read the assembly, not just the documentation. The code doesn't lie — but it can mislead if you stop at the interface.

Gas fees are the tax on human impatience. In this case, the tax is being levied on the career of a professional footballer.

This analysis is based on my reverse-engineering of Sorare's contracts as of block 19,200,000. The findings have been shared with the Sorare team responsible for security.

Market Prices

BTC Bitcoin
$64,430.8 -0.43%
ETH Ethereum
$1,862.19 +0.15%
SOL Solana
$75.94 +0.64%
BNB BNB Chain
$569.1 -0.35%
XRP XRP Ledger
$1.09 -0.09%
DOGE Dogecoin
$0.0722 -0.30%
ADA Cardano
$0.1657 -0.36%
AVAX Avalanche
$6.42 -2.42%
DOT Polkadot
$0.8154 -2.55%
LINK Chainlink
$8.36 +0.07%

Fear & Greed

28

Fear

Market Sentiment

Event Calendar

{{年份}}
28
03
unlock Arbitrum Token Unlock

92 million ARB released

30
04
upgrade Celestia Mainnet Upgrade

Improves data availability sampling efficiency

12
05
halving BCH Halving

Block reward halving event

08
04
upgrade Solana Firedancer

Independent validator client goes live on mainnet

10
05
upgrade Ethereum Pectra Upgrade

Raises validator limit and account abstraction

22
03
unlock Optimism Unlock

Circulating supply increases by about 2%

18
03
unlock Sui Token Unlock

Team and early investor shares released

15
04
halving Bitcoin Halving

Block reward reduced to 3.125 BTC

7x24h Flash News

More >
{{快讯列表(10)}} {{loop}}
{{快讯时间}}

{{快讯内容}}

{{快讯标签}}
{{/loop}} {{/快讯列表}}

Tools

All →

Altseason Index

44

Bitcoin Season

BTC Dominance Altseason

Gas Tracker

Ethereum 28 Gwei
BNB Chain 3 Gwei
Polygon 42 Gwei
Arbitrum 0.5 Gwei
Optimism 0.3 Gwei

Market Cap

All →
1
Bitcoin
BTC
$64,430.8
1
Ethereum
ETH
$1,862.19
1
Solana
SOL
$75.94
1
BNB Chain
BNB
$569.1
1
XRP Ledger
XRP
$1.09
1
Dogecoin
DOGE
$0.0722
1
Cardano
ADA
$0.1657
1
Avalanche
AVAX
$6.42
1
Polkadot
DOT
$0.8154
1
Chainlink
LINK
$8.36

🐋 Whale Tracker

🔵
0x867d...a115
30m ago
Stake
46,396 BNB
🔴
0x89f8...2800
30m ago
Out
715.90 BTC
🔴
0xe495...1b14
1d ago
Out
4,543 ETH

💡 Smart Money

0x031d...877c
Market Maker
+$4.3M
62%
0x5676...459d
Market Maker
+$1.0M
87%
0x6344...2f68
Institutional Custody
+$0.3M
85%