Whitepaper
XPower: A Proof-of-Work Token System with NFT Staking and Time-Weighted Rewards — Karun The Rich, preprint 2601 [cs.CR], January 2026
Abstract
We present XPower, a novel proof-of-work (PoW) token system deployed on the Avalanche blockchain that combines cryptographic mining with NFT-based staking and time-weighted reward mechanisms. Unlike traditional PoW cryptocurrencies that require dedicated mining infrastructure, XPower enables browser-based mining through nonce discovery using the Keccak-256 hash function. The protocol introduces a dual-token economy: XPOW (the base mining token) and APOW (an aged store-of-value derivative), complemented by ERC-1155 NFTs that serve as staking instruments. We describe the mathematical foundations of the difficulty-to-reward mapping, the polynomial-based annual percentage rate (APR) system, and the integrator mechanism for computing duration-weighted means. Our implementation includes anti-gaming protections, migration support for protocol upgrades, and dynamic rate adjustment based on staking distribution. The system achieves fair token distribution through computational work while providing long-term value accrual through the staking and aging mechanisms.
1. Introduction
The distribution of cryptocurrency tokens remains a fundamental challenge in decentralized systems. Initial Coin Offerings (ICOs) and token airdrops suffer from centralization concerns and Sybil attacks, while traditional proof-of-work mining requires significant capital investment in specialized hardware. XPower addresses these limitations by implementing a browser-accessible proof-of-work system where tokens are minted proportionally to computational difficulty achieved.
Architecture
The XPower protocol consists of six interconnected smart contracts deployed on Avalanche C-Chain:
| Contract | Alias | Type | Role |
|---|---|---|---|
| XPower | moe | ERC20 | Base proof-of-work token — mined through Keccak-256 nonce discovery |
| XPowerNft | nft | ERC1155 | Deposit receipt NFT — represents locked XPOW with tiered levels |
| APowerNft | ppt | ERC1155 | Staking receipt NFT — tracks age and shares for reward calculation |
| APower | sov | ERC20 | Store-of-value token — minted through staking rewards at a rate-limited pace |
| MoeTreasury | mty | Treasury | Reward distributor — calculates APR/APB and mints APOW on claims |
| NftTreasury | nty | Treasury | Staking manager — handles stake/unstake operations on XPowerNft ↔ APowerNft |
The token flow follows a mine → deposit → stake → claim pipeline. Miners produce XPOW through nonce discovery; depositors lock XPOW into XPowerNft positions; stakers commit these to NftTreasury to receive APowerNft receipts; those receipts accumulate time-weighted rewards claimable as APOW from MoeTreasury.
2. Related Work
Proof-of-Work Cryptocurrencies
Bitcoin pioneered proof-of-work for distributed consensus using SHA-256 double hashing with adjustable difficulty. Ethereum employed Ethash, a memory-hard PoW algorithm designed to resist ASIC mining, before transitioning to proof-of-stake. Monero uses RandomX, optimized for general-purpose CPUs.
XPower differs fundamentally: PoW is used solely for token distribution, not consensus. The underlying blockchain consensus is delegated to Avalanche's proof-of-stake mechanism, while mining determines individual token rewards.
Token Staking Mechanisms
DeFi protocols have developed various staking mechanisms. Compound introduced yield-bearing tokens (cTokens) that accrue interest continuously. Lido created liquid staking derivatives for proof-of-stake networks. Curve implemented vote-escrowed tokens (veCRV) with time-locked staking.
XPower's approach combines NFT representation with time-weighted reward calculation, allowing transferable staking positions while tracking individual stake duration — a pattern not present in any single existing protocol.
ERC-1155 Token Standard
The ERC-1155 multi-token standard enables efficient batch operations and unified handling of fungible and non-fungible tokens. XPower leverages this standard for staking NFTs, encoding both the issuance year and denomination level in the token identifier:
3. Proof-of-Work Mining
Hash Function and Nonce Discovery
Miners compute Keccak-256 over a structured input to discover a nonce
The XOR of the contract address and beneficiary address prevents nonce reuse across different recipients while maintaining a fixed-size prefix. The block hash ties computation to a specific point in Avalanche's history, preventing pre-computation attacks.
Difficulty and Reward
Difficulty level
This exponential relationship ensures that higher difficulties yield proportionally more tokens. At
Block Hash Intervals and Duplicate Prevention
Mining operates within 1-hour windows tied to Avalanche block hashes. Solutions must be submitted within 3,600 seconds of calling init(blockHash). Each (nonce-hash, block-hash) pair can only be used once, enforced via a mapping of pair indices:
Treasury Split
Every successful mint splits the reward 50/50 between the miner's beneficiary and the MoeTreasury, funding the staking reward pool and aligning incentives across the ecosystem.
4. NFT Staking
XPowerNft — Deposit Receipts
Users convert XPOW tokens to XPowerNft positions by depositing into the NFT contract. Each NFT has a denomination level
The level step of 3 enables the upgrade mechanism: 1,000 NFTs at level
Maturity and Redemption
NFTs can be redeemed back to XPOW tokens after a maturity period determined by level:
Higher-level NFTs have exponentially longer lock periods — a level 9 NFT matures in 7 years, while a level 60 NFT requires approximately one million years, making it effectively permanent.
APowerNft — Staking Receipts
When XPowerNfts are staked in the NftTreasury, users receive APowerNfts as receipts tracking:
- Staked amount per NFT identifier
- Weighted staking timestamp via an age accumulator
- Total shares per level for rate adjustment
The age accumulator follows a proportional adjustment invariant: partial unstaking preserves the average staking duration per remaining token. Age resets on transfer, preventing buyers from accumulating age bonus they did not earn.
5. Reward Calculation
Reward Formula
The reward for a staked NFT position combines a level-based base rate and an age-based loyalty bonus:
where
APR Polynomial
The APR maps an NFT's level to a base reward rate via a configurable three-term polynomial with fractional exponentiation:
Default parameters
APB Polynomial
The APB rewards older NFT vintages, mapping age in years through the same polynomial structure:
Default parameters
Dynamic Rate Adjustment and Integrator
Per-level share accumulation drives a dynamic scalar that redistributes rewards toward under-staked levels:
Rate changes are smoothed by the integrator mechanism, which computes duration-weighted arithmetic means over rate history, preventing flash-staking manipulation.
6. Migration
The protocol supports migration from previous contract versions through the Migratable base contract. Token migration allows users to convert old tokens to new tokens within an approximately 4-year deadline window (126,230,400 seconds from deployment). NFT migration uses a two-step process: burn old NFTs from the previous contract, then deposit equivalent XPOW to mint new NFTs. APower migration is atomic — burning old APOW triggers migration of the corresponding XPOW backing before minting new APOW.
Both token and SOV migration can be sealed by authorized roles (MOE_SEAL_ROLE, SOV_SEAL_ROLE), making the migration windows finite. The system attempts multiple level variations to find matching old NFTs, handling cases where level encoding changed between versions.
7. Security
Audit
The XPower smart contracts underwent a comprehensive security audit by Hacken.io in January 2024, achieving an overall score of 9.1/10 with a perfect 10/10 security score. The audit identified 6 findings (1 critical, 2 high) — all resolved:
- Critical: Block hash validity window — the timestamp comparison was corrected to enforce proper one-hour expiry
- High: NFT transfer age tracking and reward accumulation — resolved via proportional age adjustment and
refreshClaimedfunctionality - Low: Migration access controls strengthened
Banq Anti-Gaming System
The Banq library implements multiple protections:
- Minimum balance ratio: Claims must satisfy
, with excess balance burned - Supply cap: Without a lending pool, total APOW supply is capped at 43,830 tokens
- Pool locking: With a pool configured, claimed tokens are auto-supplied and locked
Reentrancy Protection
Critical functions use OpenZeppelin's ReentrancyGuardTransient, leveraging EIP-1153 transient storage for gas-efficient reentrancy prevention.
Access Control and Reparametrization Limits
Role-based access control restricts sensitive operations to APR_ROLE, APB_ROLE, and seal roles. The Rpp library constrains parameter changes to
Known Risks
The audit identified inherent risks including APOW supply variation based on claiming frequency, migration deadlines subject to sealing, dynamic rate impacts from large stakers, administrative parameter control (within bounded constraints), and APowerNft transfer reward reset.
8. Conclusion and Future Work
XPower presents a novel approach to proof-of-work token distribution that separates mining from consensus, enabling accessible participation without specialized hardware. The NFT staking system provides flexible position management with exponential tier scaling, while the time-weighted reward mechanism incentivizes long-term commitment through additive APR and APB. The polynomial-based rate system and dynamic adjustment create a self-balancing ecosystem that rewards diverse staking strategies.
Future work includes analysis of mining difficulty distribution, optimization of reward parameters based on observed staking patterns, and integration with decentralized lending protocols for the Banq lending pool.
Key Results
Expected Mining Yield: A miner performing
Staking Age Invariant: Partial unstaking preserves the average staking duration per remaining token. After burning amount
Appendices
A. Glossary
| Term | Definition |
|---|---|
| APB | Annual Percentage Bonus — additional reward rate based on NFT vintage year |
| APOW | Aged Power token — a rate-limited store-of-value token backed by XPOW |
| APR | Annual Percentage Rate — base reward rate per NFT level |
| Banq | Auto-supply and anti-gaming library for APOW claims |
| Integrator | Mechanism for computing duration-weighted arithmetic means of rate values |
| Level | NFT classification (0, 3, 6, ..., 99) determining denomination |
| RPM | Rug Pull Protection — library enforcing bounds on parameter changes |
| Shares | Accumulator tracking total staked value per NFT level for rate adjustment |
B. Contract Addresses
| Contract | Alias | Role |
|---|---|---|
| XPower | MOE | Proof-of-work ERC20 token |
| XPowerNft | NFT | ERC1155 deposit receipt |
| APowerNft | PPT | ERC1155 staking receipt |
| APower | SOV | Store-of-value ERC20 token |
| MoeTreasury | MTY | Reward distributor |
| NftTreasury | NTY | Staking manager |
Contract addresses are maintained in environment files and verifiable on Snowtrace. See Contract Addresses for current deployment addresses.
C. Mathematical Derivations
Expected Token Yield: The sum-of-geometric-series derivation shows that expected token yield per hash converges to
Age Invariant Proof: The proportional burn formula