Questions tagged [pairings]

The tag has no usage guidance.

Filter by
Sorted by
Tagged with
1 vote
0 answers
11 views
+50

How can I use BLS12-381 curve operations:EIP-2537, Whether it's on a public or private chain

Recently I have been doing an experiment to sign smart contracts with bls12-381, but I can't find any tutorial or code for this, Is there any way to do that? please tell me if you know about it.
hai zhang's user avatar
0 votes
0 answers
22 views

Can anyone figure out how this guy does arbitrage?

The owner of this tx record is constantly arbitraging for small amounts. It does these directly via pair. So it's not using a router. In my own testing I have always found that the amount of output is ...
Jack Suelman's user avatar
1 vote
1 answer
32 views

I'm having trouble sending token1 to a pair address and receiving token0

I am trying to make a swap directly via the pair address without a router. I'm trying to get token0 by sending token1. The amount of token0 I will receive does not matter, but when I run the node.js ...
Jack Suelman's user avatar
1 vote
1 answer
68 views

Pre compiled contract for alt_bn128 for scalar multiplication on G2?

Ethereum provides pre-compiled contracts for alt_bn128 curve pairing check, and point addition and scalar multiplication on G1. However, I could not find any such thing for point addition and ...
Manish Adhikari's user avatar
1 vote
1 answer
78 views

How to 'add' FQ12 points (result of pairings) when using Ethereum's py_ecc library

When implementing an algorithm like groth16, the verification step involves the addition of higher-order field elements (FQ12) resulting from pairings. How can this be achieved through Ethereum's ...
Anshu Jalan's user avatar
0 votes
0 answers
7 views

computing paring in EIP-197

I am working on bilinear paring on EIP-197. I want to compute e(g1,g2). is there anyone here to compute this value?
Amin Mohammadali's user avatar
0 votes
0 answers
80 views

ETH Sent to Uniswap V2 router after creating LP

Please help. I tried creating an LP on Uniswap V2 on Arbitrum. It turns out only v3 is available on arb one. On uniswap page, I chose v2 pool on Eth network, then on top right, I changed it to Arb one....
ven's user avatar
  • 1
1 vote
1 answer
61 views

Why TornadoCash smart contract calls address = 8?

I've trying to understand how zkSNARK works in TornadoCash. I faced with the tricky thing in the code which I cannot understand. I researched the code of this smart contract at address: https://...
Valera Dubrava's user avatar
4 votes
0 answers
109 views

How the mimc bug from circomlib was safely exploited in practice on Tornado Cash?

Several years ago, there was an unenforced constraint on verification in the cirmcomlib library : a tool for building projects using ZsNarks. The error allowed to forge cryptographic nullifiers/proofs ...
user2284570's user avatar
  • 1,008
0 votes
1 answer
394 views

Set tokenA as token0 for UniswapV2 liquidity pair contract

Hello guys I need some help! Could someone explain me how to set the token order (token0 / token1) of a liquidity pair? I’m using UniswapsV2 - Factory contract. Currently when i create a pool with ...
DarthJedi's user avatar
  • 101
1 vote
1 answer
66 views

Is it proper to estimate the throughput of verification from gas limit?

EIP-2537 says pairing of k pairs cost 23000*k + 115000 gas. Gas limit per block is 30M gas, and (30M-115000)/23000 is about 1299. Does it mean that there can be at most 1299 transactions to be ...
luke's user avatar
  • 31
0 votes
1 answer
413 views

Only getting 'Promise { <pending> } when calling getPair on the Quickswap Factory contract with ethers.js?

I'm attempting to get the pair address of the WETH/DAI pair on Quickswap on the Mumbai test net. I have this quick script: const ethers = require('ethers'); const Big = require('big.js'); const PATH = ...
Pickinanameainteasy's user avatar
1 vote
1 answer
454 views

Why is there a price difference for pair contracts and swap pair contracts in Uniswap?

I created a few bots to pull data from Uniswap. For example, using ETH/DAI. Even though the pairs are the same, the contract ID's are different for pairs and swap. Why is it that the swap price ...
ElHaix's user avatar
  • 187
3 votes
0 answers
149 views

Uniswap path generation

The uniswap contract has a function called swapTokensForExactTokens. One of the arguments to this function is an array of addresses called "path" which is the route that the transfer will ...
Rishi's user avatar
  • 31
5 votes
1 answer
4k views

How to query Uniswap api in order to get the pair ID of a chosen token?

I am using the Uniswap v2 api subgraph but I am running into a bit of an issue that I cannot resolve. Basically I want to query the api to get the latest token swaps of a chosen token and Eth. Using ...
setup369's user avatar
1 vote
0 answers
110 views

Does Ethereum support bilinear pairing calculation?

Ethereum pre-compiled x08 address can do pairing checks, but if I just want the smart contract to calculate a pairing, such as e(a,b), instead of checking whether the pairing e(a,b) is equal to e(c,d),...
user65433's user avatar
2 votes
0 answers
125 views

Does Ethereum support just bilinear pairing calculation not the pairing check?

I need to implement bilinear pairing calculation on my contract. Specifically, I have uploaded some parameters and need other users to calculate the pairing for me and I will pay for them if their ...
AdrianWH's user avatar
1 vote
0 answers
285 views

How to compute pairing in a smart contract

I am working on the elliptic curve and pairing stuff in Ethereum smart contract. How can I compute pairing such e(p1,p2)? I know that we have a pre-compile pairing check in Ethereum client which is ...
mohsen's user avatar
  • 53
2 votes
0 answers
404 views

How the following pairing equality be verified in Ethereum Smart contracts?

I have found available precompiled contracts in solidity. For example, this answer enter link description here points out a precompiled contract that can verify BLS signature. However, looking at the ...
Heba Mohsen's user avatar
2 votes
1 answer
365 views

Errors in when compiling the BLS signature in remix?

Etherum can verify BLS signatures, In this answer Does Ethereum support pairing operations? There is an example of how to verify BLS in solidity. However, when I tried to test the code in remix, ...
Mohamed's user avatar
  • 491
3 votes
1 answer
2k views

Does Ethereum support pairing operations?

I need to build an application that uses bilinear pairing operations for generating signatures. If I send a message with its signature to Ethereum, can Ethereum verify this message? Does the EVM ...
Mohamed's user avatar
  • 491
7 votes
1 answer
2k views

How can we verify BGLS aggregate signatures in Solidity?

BGLS [1] is an aggregate signature scheme by Boneh et al., that allows aggregation of signatures on n different messages from n different signers. What I want to achieve is to verify such signatures ...
Saffie's user avatar
  • 235
4 votes
1 answer
785 views

How to use Ethereum precompile bn256Pairing to check equality on symmetric groups?

The address 0x8 contains bn256Pairing pre-compiled contract on Byzantium release. I have the following questions : If I have G_1 = G_2, i.e., a symmetric pairing, is it possible to check e(a_1, b_1) ?...
pseudorandom's user avatar
3 votes
0 answers
428 views

Can the precompiles in Byzantium for pairings be used for implementation of BLS verification?

I am looking into implementing some operations for the BLS signature scheme in Solidity, using the new precompiled contracts for pairing operations released with Byzantium. In BLS verification, to ...
charleslu's user avatar
  • 133