The idea was proposed by Lev Soukhanov @levs57
Current RLN circuit uses first-degree polynomial for shares generation (and slashing). Therefore, there is a limit - one message per epoch.
There have been attempts to make schemes in which the message limit per epoch is greater than one. For example N-RLN scheme. But this approach is very problematic, cause the bigger the limit - the more complicated is the circuit (more R1CS, etc.).
Instead of using higher degree polynomials we can just add additional input to hash-function (for a1
coefficient generation) - counter.
So, for the epoch limit n
, the scheme will be:
A(X) = a_0 + a_1 * x
, where
a_0
- secret generated by usera_1
- Hash(a_0, external_nullifier, k)
, where 1 <=
k <= n
internal_nullifier = Hash(a_1)
Only thing we need to check is that the k
parameter is in the range from 1 to n = epoch limit
. Therefore user won't be able to use k > n
, and if user uses same k
twice they'll be slashed.
Thus, the scheme remains as simple as it was while at the same time providing more flexibility.
There are also other cool features that come along with using this scheme:
By using this scheme we can create circuit, that will allow us to use different rate-limits for different users, for example based on their stake.
We can do that by commiting to not only our secret, but our secret and limit:
pubkey = Hash(privkey)
) of users and values are some metadata (for example limit
number or stake amount);Hash(pubkey, limit)
For example, the possible limit is 1000 (n
= 1000), and each message costs 0.001 ETH (so you will have 1000 messages limit if you stake 1 ETH).
So, when you join app you attach the amount of stake you want and also send the pubkey
and commitment = Hash(pubkey, limit)
, and zk-proof that the limit (public input for the circuit) you set for yourself is correct.
Signalling will use other circuit, where your limit
is private input, and the counter k
is checked that it's in the range from 1 to limit
.
or
or
By clicking below, you agree to our terms of service.
New to HackMD? Sign up
Syntax | Example | Reference | |
---|---|---|---|
# Header | Header | 基本排版 | |
- Unordered List |
|
||
1. Ordered List |
|
||
- [ ] Todo List |
|
||
> Blockquote | Blockquote |
||
**Bold font** | Bold font | ||
*Italics font* | Italics font | ||
~~Strikethrough~~ | |||
19^th^ | 19th | ||
H~2~O | H2O | ||
++Inserted text++ | Inserted text | ||
==Marked text== | Marked text | ||
[link text](https:// "title") | Link | ||
 | Image | ||
`Code` | Code |
在筆記中貼入程式碼 | |
```javascript var i = 0; ``` |
|
||
:smile: | ![]() |
Emoji list | |
{%youtube youtube_id %} | Externals | ||
$L^aT_eX$ | LaTeX | ||
:::info This is a alert area. ::: |
This is a alert area. |
On a scale of 0-10, how likely is it that you would recommend HackMD to your friends, family or business associates?
Please give us some advice and help us improve HackMD.
Do you want to remove this version name and description?
Syncing