Compliance in Uniswap v4
Over the past month, I had the opportunity to participate in the Uniswap Hook Incubator, a builder-focused cohort hosted by Atrium and supported by the Uniswap Foundation.
I wanted to learn more about the design space for hooks in Uniswap v4 and work out a product at the end regarding v4 hook technology, which resulted in kvhook
.
Why Hooks?
Uniswap v4 introduces a new primitive: hooks. Hooks are external smart contracts that can be though of as a plugin on various different executions ina lifecycle of a Uniswap pool. Actions like beforeSwap
, afterSwap
, beforeAddLiquidity
, etc which is quite explainatory.
You can think of hooks as programmable policy modules for pools. They allow developers to customize swap and liquidity logic without modifying the underlying AMM core. This architectural separation increases protocol security because developers no longer need to modify or even fully grasp the internal mechanics of the core, which is mostly the most complex part of a protocol where small erros can lead to large losses.
The behaviour of v4 hooks as separate hook contracts, reduces the risk of inadvertently introducing bugs or vulnerabilities into the foundational AMM logic. Composability is likewise enhanced, as developers can now innovate at the periphery.

With making the developer only focus on the product as an layer ontop of a stable, canonical core we can say Uniswap v4 is, we eliminate the risk of historical major protocol erros that often have stemed from inexperienced teams attempting to fork and modify Uniswap v2 or v3.
With v4, hooks introduce a safer and more modular approach to protocol development by isolating custom logic, enabling expansion while preserving the integrity of the core protocol logic.
Hooks open the door for things like:
- Dynamic fees
- Lp rebalancing
- Loss Versus Rebalancing
- Permissioned pools
- ...etc
The Problem: No Identity Layer in DeFi
DeFi is for everyone. It's permissionless, and open. That’s what I think makes it powerful. But it’s also what makes it difficult for institutions and regulated assets to participate and trust platforms.
I got quite intrugued by the Request for hooks page from the sponsors like EigenLayer, Circle, Flaunch etc, but one request stood out to me.
Ink, on their list for reqest for hooks, the first request stood out to me:

Using Kraken Verify, create permissioned pools using
beforeSwap
to query address verification(s).
Start of hookathon
I started out with trying to solve and create a product for the "Derivatives" idea, since I have in the past worked with syntetic option contracts, but not on Uniswap v4. I quickly relized that I did not have the time to build out the product with the vision I had in mind after accounting for time.
Instead I decided to try and solve the permissioned pools idea, 2 days before the hookathon ended...
I really liked the idea of the permissioned pools, and I thought it would be a good way to explore the hook technology, with beeing able to integrate with new tech, deploy on a new chain and use Ethereum Attestation Service (EAS).
What solidifed the pivot was the fact that DeFi lacks an identity layer. Kraken Verify introduces one.
By integrating it with Uniswap v4, I could try to bring verifiable identity to pools, without exsposing personal data 🎉
kvhook
-> Kraken Verify Hook
kvhook
is a Uniswap v4 hook that enforces KYC-gated swaps using Kraken Verify and the Ethereum Attestation Service (EAS).
How it works:
- Users verify themselves through Kraken Verify.
- Kraken issues an on-chain attestation (via EAS).
- When a user tries to swap,
kvhook
checks their attestation in thebeforeSwap
logic. - If the wallet is verified → the swap proceeds.
- If not → the transaction reverts.
Simple as that! No more fluff.
No personal data is exposed. The only thing the hook sees is the on-chain proof that Kraken has verified this wallet.
This creates compliant but still private pools to the users whom are verified.

Why It Matters
I think this is a good PoC to showcase the potential of hooks in Uniswap v4, and the ability to demonstrate that in such decentralized systems, it is possible to comply with regulations, eventhough the core principles of blockchain and DeFi are trust minimization.
By leveraging onchain attestation services, we can prove facts about ourselves without sharing private data. The protocol for product only verifies the vailidty of the proof, never the fact itself.
With thinking a little bit ahead, this type of products can unlock new structures of fees and reward programs for LPs in AMMs, all with percerving the decentralization of the protocol.
Results
Despite the challenges regarding time and deployment issues, kvhook
ended up placing 2nd in the INK track of the incubator 🎉
This wasn’t something I expected when joining the hookathon program, it began mostly as a personal exploration. But I’m excited that Kraken saw the potential in the product and recognized that it’s not just another blockchain grift with no real value or use as most hackathons projects are.

What’s Next?
I’m really interested in working more on reward structures and incentive programs for LPs in AMMs, maybe in special premissioned pools.
If you’re working on something related—or want to jam on Uniswap v4 hooks, feel free to reach out.
Thanks again to Atrium, Kraken, INK, and Uniswap Foundation for making this possible 🦄