o1js
Version:
TypeScript framework for zk-SNARKs and zkApps
1,044 lines (1,040 loc) • 1.21 MB
JavaScript
"use strict";
var __create = Object.create;
var __defProp = Object.defineProperty;
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
var __getOwnPropNames = Object.getOwnPropertyNames;
var __getProtoOf = Object.getPrototypeOf;
var __hasOwnProp = Object.prototype.hasOwnProperty;
var __export = (target, all) => {
for (var name in all)
__defProp(target, name, { get: all[name], enumerable: true });
};
var __copyProps = (to, from, except, desc) => {
if (from && typeof from === "object" || typeof from === "function") {
for (let key of __getOwnPropNames(from))
if (!__hasOwnProp.call(to, key) && key !== except)
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
}
return to;
};
var __toESM = (mod2, isNodeMode, target) => (target = mod2 != null ? __create(__getProtoOf(mod2)) : {}, __copyProps(
// If the importer is in node compatibility mode or this is not an ESM
// file that has been converted to a CommonJS file using a Babel-
// compatible transform (i.e. "__esModule" has not been set), then set
// "default" to the CommonJS "module.exports" for node compatibility.
isNodeMode || !mod2 || !mod2.__esModule ? __defProp(target, "default", { value: mod2, enumerable: true }) : target,
mod2
));
var __toCommonJS = (mod2) => __copyProps(__defProp({}, "__esModule", { value: true }), mod2);
// dist/node/index.js
var index_exports = {};
__export(index_exports, {
Account: () => Account4,
AccountUpdate: () => AccountUpdate3,
AccountUpdateForest: () => AccountUpdateForest,
AccountUpdateTree: () => AccountUpdateTree,
Bool: () => Bool4,
Bytes: () => Bytes2,
Cache: () => Cache,
Character: () => Character,
Circuit: () => Circuit,
CircuitString: () => CircuitString,
Core: () => bindings_exports,
Crypto: () => Crypto,
DynamicArray: () => DynamicArray,
DynamicProof: () => DynamicProof,
EcdsaSignature: () => EcdsaSignature2,
Empty: () => Empty,
Encoding: () => encoding_exports,
Encryption: () => encryption_exports,
Experimental: () => Experimental,
FeatureFlags: () => FeatureFlags,
Field: () => Field4,
ForeignCurve: () => ForeignCurve,
Gadgets: () => Gadgets,
Group: () => Group3,
Hash: () => Hash,
Hashed: () => Hashed,
IndexedMerkleMap: () => IndexedMerkleMap2,
Int64: () => Int64,
Keccak: () => Keccak,
Keypair: () => Keypair,
Ledger: () => Ledger,
Lightnet: () => Lightnet,
MerkleList: () => MerkleList,
MerkleListIterator: () => MerkleListIterator,
MerkleMap: () => MerkleMap,
MerkleMapWitness: () => MerkleMapWitness,
MerkleTree: () => MerkleTree,
MerkleWitness: () => MerkleWitness,
Mina: () => mina_exports,
Nullifier: () => Nullifier,
Option: () => Option,
Packed: () => Packed,
Permissions: () => Permissions,
Poseidon: () => Poseidon2,
PrivateKey: () => PrivateKey2,
Proof: () => Proof,
Provable: () => Provable,
ProvableType: () => ProvableType,
PublicKey: () => PublicKey2,
Reducer: () => Reducer,
Scalar: () => Scalar3,
ScalarField: () => ScalarField,
SelfProof: () => SelfProof,
Sign: () => Sign3,
Signature: () => Signature2,
SmartContract: () => SmartContract,
State: () => State2,
Struct: () => Struct,
TokenAccountUpdateIterator: () => TokenAccountUpdateIterator,
TokenContract: () => TokenContract,
TokenId: () => TokenId4,
TokenSymbol: () => TokenSymbol,
Transaction: () => Transaction,
TransactionVersion: () => TransactionVersion3,
TupleN: () => TupleN,
Types: () => transaction_exports,
UInt32: () => UInt322,
UInt64: () => UInt642,
UInt8: () => UInt8,
Unconstrained: () => Unconstrained,
Undefined: () => Undefined,
VerificationKey: () => VerificationKey2,
Void: () => Void,
ZkProgram: () => ZkProgram,
ZkappPublicInput: () => ZkappPublicInput,
addCachedAccount: () => addCachedAccount,
assert: () => assert3,
checkZkappTransaction: () => checkZkappTransaction,
circuitMain: () => circuitMain,
createEcdsa: () => createEcdsa,
createForeignCurve: () => createForeignCurve,
createForeignField: () => createForeignField,
declareMethods: () => declareMethods,
declareState: () => declareState,
fetchAccount: () => fetchAccount,
fetchEvents: () => fetchEvents2,
fetchLastBlock: () => fetchLastBlock,
fetchTransactionStatus: () => fetchTransactionStatus,
initializeBindings: () => initializeBindings,
method: () => method,
provable: () => provable,
provableFromClass: () => provableFromClass,
provablePure: () => provablePure,
public_: () => public_,
sendZkapp: () => sendZkapp,
setArchiveGraphqlEndpoint: () => setArchiveGraphqlEndpoint,
setGraphqlEndpoint: () => setGraphqlEndpoint,
setGraphqlEndpoints: () => setGraphqlEndpoints,
setNumberOfWorkers: () => setNumberOfWorkers,
state: () => state,
toPoint: () => toPoint,
verify: () => verify2
});
module.exports = __toCommonJS(index_exports);
// dist/node/lib/util/errors.js
var lineRemovalKeywords = [
"o1js_node.bc.cjs",
"/builtin/",
"CatchAndPrettifyStacktrace"
// Decorator name to remove from stacktrace (covers both class and method decorator)
];
function prettifyStacktrace(error) {
error = unwrapMlException(error);
if (!(error instanceof Error) || !error.stack)
return error;
const stacktrace = error.stack;
const stacktraceLines = stacktrace.split("\n");
const newStacktrace = [];
for (let i = 0; i < stacktraceLines.length; i++) {
const shouldRemoveLine = lineRemovalKeywords.some((lineToRemove) => stacktraceLines[i].includes(lineToRemove));
if (shouldRemoveLine) {
continue;
}
const trimmedLine = trimPaths(stacktraceLines[i]);
newStacktrace.push(trimmedLine);
}
error.stack = newStacktrace.join("\n");
return error;
}
async function prettifyStacktracePromise(result) {
try {
return await result;
} catch (error) {
throw prettifyStacktrace(error);
}
}
function unwrapMlException(error) {
if (error instanceof Error)
return error;
if (Array.isArray(error) && error[2] instanceof Error)
return error[2];
return error;
}
function trimPaths(stacktracePath) {
const includesO1js = stacktracePath.includes("o1js");
if (includesO1js) {
return trimO1jsPath(stacktracePath);
}
const includesOpam = stacktracePath.includes("opam");
if (includesOpam) {
return trimOpamPath(stacktracePath);
}
const includesWorkspace = stacktracePath.includes("workspace_root");
if (includesWorkspace) {
return trimWorkspacePath(stacktracePath);
}
return stacktracePath;
}
function trimO1jsPath(stacktraceLine) {
const fullPath = getDirectoryPath(stacktraceLine);
if (!fullPath) {
return stacktraceLine;
}
const o1jsIndex = fullPath.indexOf("o1js");
if (o1jsIndex === -1) {
return stacktraceLine;
}
const prefix = stacktraceLine.slice(0, stacktraceLine.indexOf("(") + 1);
const updatedPath = fullPath.slice(o1jsIndex);
return `${prefix}${updatedPath})`;
}
function trimOpamPath(stacktraceLine) {
const fullPath = getDirectoryPath(stacktraceLine);
if (!fullPath) {
return stacktraceLine;
}
const opamIndex = fullPath.indexOf("opam");
if (opamIndex === -1) {
return stacktraceLine;
}
const updatedPathArray = fullPath.slice(opamIndex).split("/");
const libIndex = updatedPathArray.lastIndexOf("lib");
if (libIndex === -1) {
return stacktraceLine;
}
const prefix = stacktraceLine.slice(0, stacktraceLine.indexOf("(") + 1);
const trimmedPath = updatedPathArray.slice(libIndex + 1);
trimmedPath.unshift("ocaml");
return `${prefix}${trimmedPath.join("/")})`;
}
function trimWorkspacePath(stacktraceLine) {
const fullPath = getDirectoryPath(stacktraceLine);
if (!fullPath) {
return stacktraceLine;
}
const workspaceIndex = fullPath.indexOf("workspace_root");
if (workspaceIndex === -1) {
return stacktraceLine;
}
const updatedPathArray = fullPath.slice(workspaceIndex).split("/");
const prefix = stacktraceLine.slice(0, stacktraceLine.indexOf("(") + 1);
const trimmedPath = updatedPathArray.slice(workspaceIndex);
return `${prefix}${trimmedPath.join("/")})`;
}
function getDirectoryPath(stacktraceLine) {
const fullPathRegex = /\(([^)]+)\)/;
const matchedPaths = stacktraceLine.match(fullPathRegex);
if (matchedPaths) {
return matchedPaths[1];
}
}
function Bug(message) {
return Error(`${message}
This shouldn't have happened and indicates an internal bug.`);
}
function assert(condition, message = "Failed assertion.") {
if (!condition)
throw Bug(message);
}
// dist/node/lib/util/types.js
var Tuple = {
map(tuple2, f) {
return tuple2.map(f);
}
};
var TupleN = {
map(tuple2, f) {
return tuple2.map(f);
},
fromArray(n, arr) {
assert(arr.length === n, `Expected array of length ${n}, got ${arr.length}`);
return arr;
},
hasLength(n, tuple2) {
return tuple2.length === n;
}
};
// dist/node/bindings/crypto/constants.js
var prefixes = {
event: "MinaZkappEvent******",
events: "MinaZkappEvents*****",
sequenceEvents: "MinaZkappSeqEvents**",
zkappBodyMainnet: "MainnetZkappBody****",
zkappBodyTestnet: "TestnetZkappBody****",
accountUpdateCons: "MinaAcctUpdateCons**",
accountUpdateNode: "MinaAcctUpdateNode**",
zkappMemo: "MinaZkappMemo*******",
signatureMainnet: "MinaSignatureMainnet",
signatureTestnet: "CodaSignature*******",
zkappUri: "MinaZkappUri********",
deriveTokenId: "MinaDeriveTokenId***",
sideLoadedVK: "MinaSideLoadedVk****"
};
var prefixHashes = {
"CodaReceiptUC*******": [
"2930292359494829300271368860633580634815819151887078160583250237349129726103",
"15303314845540397914948764201521841781296890621466368017042313538410516382474",
"8520568699315305732843613022173524514377597839978192694761879649747314556194"
],
"CodaReceiptZkapp****": [
"10173709693039436418323173817852473796760618468635274081106091878172355412495",
"8139892805413950771311540201181177376747817902069998595519899391903936767134",
"13514876620613630149351219463845257700223634963001020028151406467995275024594"
],
"Coinbase************": [
"16825847102297458526359719396083434368788313103713242309655412848174457920423",
"21732702256017917816272795771734458959259892802453584375610183841451053027064",
"20669950187190141732603807229833302926112666951294341954340514712643194206110"
],
"PendingCoinbases****": [
"16730315671906078134534118281698719603694322959719576832314142406897554025946",
"25168172107432119701402092802564698772609386283424806773354665411015030859956",
"20203823516569384790863281992678977204769111540506990077513414850340465376267"
],
"CoinbaseStackData***": [
"23795978781100345043289806728009175185120094645976380845310050347461663815988",
"22848259504294538625391413055517172710405127059374914145881816600826824598643",
"8292468073974572410325570929211069869427868613763277519881895337391418731450"
],
CoinbaseStackStaHash: [
"335203117218289187585524630708440909952721586869179589604793956147132569543",
"27066428515933869709871979311099618239824992817474733219473754649926311088531",
"21249847167218596842529246266817628519376871370045151307329588726090940941283"
],
"CoinbaseStack*******": [
"10365018507282248303752506973112854406071106890516858854157506926717812932750",
"19289691782405010481159082968251292806607879795611766141901748131065655579721",
"8987039650233860747996941600635099179155585390854763935988086491644855810711"
],
"MinaCheckpoints*****": [
"15873130589302091361863210575263731242593763730169570459166821652327279429416",
"27741778946681194402252199348726997679847260280438775383573755416459042152245",
"7598438620402360345138640933713109733801127070065255775405685972203496634081"
],
"MinaMergeSnark******": [
"5465206932306554741198859294482250047374987110116571903153751264716396266207",
"28325265961862852836567844362114881306407823522046946129773393861560948847052",
"20049678444717746759028157787181298288785775657186008836042341914370292827996"
],
"MinaBaseSnark*******": [
"15502310217431654911062859746106286672455410530942120153504175184205809302248",
"3469045624943527165009161295743804688154058669917024998601801713171804105078",
"16667965011323249535055526937874001443515091810412343722400939445165393857780"
],
"MinaProtoState******": [
"5218970939948495870036503265499543025475317910763049867270287867667146978870",
"7663210626148314949787033187186036425676070286961909238040356477815169631084",
"19859188289320816036969227839574854326171440874550138016648548415357198703337"
],
"MinaProtoStateBody**": [
"3548547909990922956559515810876765435326873020883079662683136168632773655275",
"134182536761489093478066959027928272525080293912190881939140820794450385287",
"18910449726094816833941350890285540874861148441082116020102338532207375519343"
],
"MinaVrfMessage******": [
"24101363367502572671624471609928959797353672294440762288404204895418767914646",
"5171820881164007689309616183632792746219180909518238150637460314245246143263",
"10979796915023089328772347959806029121878467684484216605075459818053899045444"
],
MinaSignatureMainnet: [
"28597293842583882050529337819282358444728515448690248936274177901465134844489",
"13029865398778858891320837481651890827971447635226272051516204921834229015884",
"2324960771278703080070347074343683653953770644553957353754880132143131569147"
],
"CodaSignature*******": [
"6547874669265470003564181123405173756111990160585052594027544303901364349512",
"22191763046611062479784309793717481299019591714391827084400612211604078633201",
"15360317550574394687602808211901764964514686767298144053612144955373862517277"
],
"MinaVrfOutput*******": [
"2251514781415689779315070305878469259850299612928948069881728941286436529416",
"28445424317765931437563566658155841532256907311948842353165636913979445243675",
"1697103740469522139030362533818365124680980524626250761960654638291888644330"
],
"MinaVrfEvaluation***": [
"28080055385183205248434069314913715411795750554846638282391132356635075327118",
"25018718747831549163470950235902703474807728450690404911050923194299837536932",
"3256623657773355300700179149632147114566124258546613752475489953689825740823"
],
"MinaEpochSeed*******": [
"7920024158807749362970659876749181530334941449960381128739613586571256360405",
"13756862713999441076472977832321298402266591073703520273734381195492800342833",
"16931743843465107540110860558687538825985475311420101960428698400767332393906"
],
"MinaTransitionSnark*": [
"11049595972041980914958840531625028328602860712038036656362464370121336040984",
"24369517789348117364784880800333031735213111703459853079908318927717982912175",
"996573540734206293061884582007205418029995442386259428924494388795357965385"
],
"MinaAccount*********": [
"21547009634669789644192675386133007766042650219024716227935570378579547706642",
"3869977418072959680344087467966431440327948593054069717779845397512987438978",
"17591003611016737523041467644989399067682599282318802410210271366172380277153"
],
"MinaSideLoadedVk****": [
"27153629295534844750482612843518005572402188741101822965689207110291504095805",
"11073437601016088346212553894160581939150688827288603152461976873708720172824",
"9169013693168830396847022454402673046094697740892173219744332585469764409612"
],
"MinaZkappAccount****": [
"11742420651603425685690711434636216727968618158667382343736587130720645535016",
"20917169788479399921968659996772666237321879817943938162255353371266230737562",
"20221577186851444354528754069740362935513598751580381763045954351047955571417"
],
"MinaZkappPayload****": [
"15735138827391397348912010094577234813869450438840158969759900004702547928125",
"25095612872941242247876048162039143509752212627701285511972307921367391645919",
"7245494597725009330136300549232949784423520250577599502394596645257342395146"
],
"MainnetZkappBody****": [
"10214915150831852734808709087755641273868350720962413399868532305813227181967",
"19231103515031626108540280352804904215178644233964839448405623573586547300771",
"3202185325412846279878024015439663797323768206239602518916650099275135615824"
],
"TestnetZkappBody****": [
"20037733640875789833090442509053816933966165101372309054048970230906793051053",
"1106678471497583468621635190733109842219273971961053291385773425960251864224",
"25565387364959491931899708566015584890804577695743228799735258954982776499278"
],
"MinaZkappPred*******": [
"1288860557840839698672685006364179285130411098848600694737282320588924548492",
"24648295833336558525603848295184424886548932461541421142783307792871113347031",
"1330615836835056811243082335077124866238751435915242573993316916713469087050"
],
"MinaZkappPredAcct***": [
"16247099195538206941970428186933809576049890124762896310373916059400681012938",
"15171999803179862436296250357712424012107969488385552487664863256867849154640",
"4695118160519310765712802705640939163487421977728313886668234870398464448283"
],
"MinaZkappPredPS*****": [
"28115844434401213157045670864292277190427496512916771660477513364996586226191",
"17764239860871865704512758086410304367016330694375482081848267812860896213477",
"2608563583120825722034995217249250504732387097295075568312443453761249924462"
],
"MinaAcctUpdAcctPred*": [
"11173347481325879282537380504137543614432174467122278589147153842480174214350",
"22433785030516935555884954114999194863743668497200511950547006360846720681436",
"4261224905860522407514587942832658209487173552801239748203234114069543449134"
],
"MinaAcctUpdateCons**": [
"7974184247425786365466969127827083941281743695327546149120833518746435921046",
"1079147682067570431747049877519099849334832444581201545961023544596733431550",
"9670106619202136718451303928765479503313491401619698334696903962327538130992"
],
"MinaAcctUpdateNode**": [
"15921812961830232432174711488904180713275251781093575291539345321597011303739",
"5852213322332241594845871336918115662219071361771346507406094569679662937607",
"21122827334147180286039671993443893600964526985496742826857975683524856341379"
],
"MinaAcctUpdStckFrm**": [
"1223279431820750727612295994589444883292600761079562536688416996919972234987",
"1873141333924103856860857609363983758885824745969813373245393521390926426683",
"3550105212452130151915860825756512345408015936295894584118372238840612023788"
],
MinaActUpStckFrmCons: [
"2363089775097766730570162674460603870980415123701610894146069429352874281636",
"8717086429614898734892919627864489205116600585932141922995487227707208282057",
"14660270392332597302006144557344641683528071714290878702086758222477469533211"
],
"MinaZkappUri********": [
"534822897390732927195976832726937157108052596941484097303405936433225931144",
"21308674973525253012607500915181592359821899373849668837401701284134790635210",
"19235616568963430752220890547731083898076295596325584947617173371158207986317"
],
"MinaZkappEvent******": [
"4144672248660824652311280789227568759501644435839088465487215978090977152836",
"16580012705864177241905923711864666027965216928284588602669501632136706453456",
"28268897103231723777184618409092967932555901943057586428182153116992131011025"
],
"MinaZkappEvents*****": [
"22941690192200157010958144262626906691861453230235765939870625581651903942109",
"8085194290973996063041942057794139208480036474122767282118588735695477304146",
"26729904183313179836453835886592671283117737890095730465188585661277543615385"
],
"MinaZkappSeqEvents**": [
"20111532619758468729019280527752703188436440291616049387250019116440725105679",
"28272901079534355755544153990297346241256584111406088887261772513761686581936",
"11593971643819429831651280663135869674712971584194549509498204047075895747923"
],
"MinaZkappMemo*******": [
"2662735671148484138098041239517130399444285195614926917304994766121342901330",
"1889560324711062089177091328630260720221153765601231238715650562289804935970",
"4150523804923664151142435309968051550133270766858171566059780615187901817023"
],
"MinaZkappTest*******": [
"23523101868899742954180674496902908392567863852999903167375927084079494055612",
"4491786955849351692402874941062803293792761915358826996649017458255778371918",
"18160445324611651688025194683090940451613686777550031421971998315243738422364"
],
"MinaDeriveTokenId***": [
"6192019453766080264591455948244350296532066491511280821771403784079613278630",
"3474280028978446563781013959252007045004226094384968366087940198662654278266",
"20434002876694963787609307807174199928279086350854834006718281273564667456637"
],
CodaReceiptEmpty: [
"14564582992068613478915821183083107733064540968050799295374021047658500056219",
"21765043973285063733734239399942750176857972907855721619600674857294623000734",
"18519955733587546799174091248819038069762857427193969217428957100491271613694"
],
MinaZkappEventsEmpty: [
"11558119263070965853863267079253872832625419457395008685779236645292569607921",
"25458142203119307439619503192644060065091275427503371449742352140981637359577",
"28343474290528262467651243371210869540984529302238754668057531270656874883506"
],
MinaZkappActionsEmpty: [
"2965377540200775924504968637505084669999360240500907972788072774778139588064",
"17888733104410001265760460027725887240172765470923695174284923303416908725309",
"6155733123951817300356401771271939707310716210385193729101357561319788034953"
],
MinaZkappActionStateEmptyElt: [
"25079927036070901246064867767436987657692091363973573142121686150614948079097",
"26431778411571512074795067173224334387034335867358343719815640998216694007738",
"25080775363764450744501815075506845022058095277795060631172637381645274354727"
],
CoinbaseStack: [
"13478948633790621346997153068092516261975764161208078295837519850718904039733",
"23794571567771902109532327523992257297445027552423990566905688786749549749640",
"12437776415960587857483436445253285567999534294199440886476575966193776753527"
],
PendingCoinbaseMerkleTree: [
"21962074494103541153175746450273873003299668759086391980006382367241943398196",
"2903435713642676558047328375873609628346075739786101737671585224825766548393",
"25831764682100331646870313396659195191400312071282528592914032765816857800473"
]
};
var prefixHashesLegacy = {
"CodaReceiptUC*******": [
"17081977821176270994512651394491195177111442160604726653596300537904083542874",
"22524836078442467808299966370016521142448937585030982609163888361124501146539",
"12924279821307137198726349959646209575189430925513631516289320462608412110369"
],
MinaSignatureMainnet: [
"25220214331362653986409717908235786107802222826119905443072293294098933388948",
"7563646774167489166725044360539949525624365058064455335567047240620397351731",
"171774671134240704318655896509797243441784148630375331692878460323037832932"
],
"CodaSignature*******": [
"28132119227444686413214523693400847740858213284875453355294308721084881982354",
"24895072146662946646133617369498198544578131474807621989761680811592073367193",
"3216013753133880902260672769141972972810073620591719805178695684388949134646"
]
};
var versionBytes = {
tokenIdKey: 28,
receiptChainHash: 12,
ledgerHash: 5,
epochSeed: 13,
stateHash: 16,
publicKey: 203,
userCommandMemo: 20,
privateKey: 90,
signature: 154,
transactionHash: 29,
signedCommandV1: 19
};
var protocolVersions = { txnVersion: 3 };
var poseidonParamsKimchiFp = {
mds: [
[
"12035446894107573964500871153637039653510326950134440362813193268448863222019",
"25461374787957152039031444204194007219326765802730624564074257060397341542093",
"27667907157110496066452777015908813333407980290333709698851344970789663080149"
],
[
"4491931056866994439025447213644536587424785196363427220456343191847333476930",
"14743631939509747387607291926699970421064627808101543132147270746750887019919",
"9448400033389617131295304336481030167723486090288313334230651810071857784477"
],
[
"10525578725509990281643336361904863911009900817790387635342941550657754064843",
"27437632000253211280915908546961303399777448677029255413769125486614773776695",
"27566319851776897085443681456689352477426926500749993803132851225169606086988"
]
],
roundConstants: [
[
"21155079691556475130150866428468322463125560312786319980770950159250751855431",
"16883442198399350202652499677723930673110172289234921799701652810789093522349",
"17030687036425314703519085065002231920937594822150793091243263847382891822670"
],
[
"25216718237129482752721276445368692059997901880654047883630276346421457427360",
"9054264347380455706540423067244764093107767235485930776517975315876127782582",
"26439087121446593160953570192891907825526260324480347638727375735543609856888"
],
[
"15251000790817261169639394496851831733819930596125214313084182526610855787494",
"10861916012597714684433535077722887124099023163589869801449218212493070551767",
"18597653523270601187312528478986388028263730767495975370566527202946430104139"
],
[
"15831416454198644276563319006805490049460322229057756462580029181847589006611",
"15171856919255965617705854914448645702014039524159471542852132430360867202292",
"15488495958879593647482715143904752785889816789652405888927117106448507625751"
],
[
"19039802679983063488134304670998725949842655199289961967801223969839823940152",
"4720101937153217036737330058775388037616286510783561045464678919473230044408",
"10226318327254973427513859412126640040910264416718766418164893837597674300190"
],
[
"20878756131129218406920515859235137275859844638301967889441262030146031838819",
"7178475685651744631172532830973371642652029385893667810726019303466125436953",
"1996970955918516145107673266490486752153434673064635795711751450164177339618"
],
[
"15205545916434157464929420145756897321482314798910153575340430817222504672630",
"25660296961552699573824264215804279051322332899472350724416657386062327210698",
"13842611741937412200312851417353455040950878279339067816479233688850376089318"
],
[
"1383799642177300432144836486981606294838630135265094078921115713566691160459",
"1135532281155277588005319334542025976079676424839948500020664227027300010929",
"4384117336930380014868572224801371377488688194169758696438185377724744869360"
],
[
"21725577575710270071808882335900370909424604447083353471892004026180492193649",
"676128913284806802699862508051022306366147359505124346651466289788974059668",
"25186611339598418732666781049829183886812651492845008333418424746493100589207"
],
[
"10402240124664763733060094237696964473609580414190944671778761753887884341073",
"11918307118590866200687906627767559273324023585642003803337447146531313172441",
"16895677254395661024186292503536662354181715337630376909778003268311296637301"
],
[
"23818602699032741669874498456696325705498383130221297580399035778119213224810",
"4285193711150023248690088154344086684336247475445482883105661485741762600154",
"19133204443389422404056150665863951250222934590192266371578950735825153238612"
],
[
"5515589673266504033533906836494002702866463791762187140099560583198974233395",
"11830435563729472715615302060564876527985621376031612798386367965451821182352",
"7510711479224915247011074129666445216001563200717943545636462819681638560128"
],
[
"24694843201907722940091503626731830056550128225297370217610328578733387733444",
"27361655066973784653563425664091383058914302579694897188019422193564924110528",
"21606788186194534241166833954371013788633495786419718955480491478044413102713"
],
[
"19934060063390905409309407607814787335159021816537006003398035237707924006757",
"8495813630060004961768092461554180468161254914257386012937942498774724649553",
"27524960680529762202005330464726908693944660961000958842417927307941561848461"
],
[
"15178481650950399259757805400615635703086255035073919114667254549690862896985",
"16164780354695672259791105197274509251141405713012804937107314962551600380870",
"10529167793600778056702353412758954281652843049850979705476598375597148191979"
],
[
"721141070179074082553302896292167103755384741083338957818644728290501449040",
"22044408985956234023934090378372374883099115753118261312473550998188148912041",
"27068254103241989852888872162525066148367014691482601147536314217249046186315"
],
[
"3880429241956357176819112098792744584376727450211873998699580893624868748961",
"17387097125522937623262508065966749501583017524609697127088211568136333655623",
"6256814421247770895467770393029354017922744712896100913895513234184920631289"
],
[
"2942627347777337187690939671601251987500285937340386328746818861972711408579",
"24031654937764287280548628128490074801809101323243546313826173430897408945397",
"14401457902976567713827506689641442844921449636054278900045849050301331732143"
],
[
"20170632877385406450742199836933900257692624353889848352407590794211839130727",
"24056496193857444725324410428861722338174099794084586764867109123681727290181",
"11257913009612703357266904349759250619633397075667824800196659858304604714965"
],
[
"22228158921984425749199071461510152694025757871561406897041788037116931009246",
"9152163378317846541430311327336774331416267016980485920222768197583559318682",
"13906695403538884432896105059360907560653506400343268230130536740148070289175"
],
[
"7220714562509721437034241786731185291972496952091254931195414855962344025067",
"27608867305903811397208862801981345878179337369367554478205559689592889691927",
"13288465747219756218882697408422850918209170830515545272152965967042670763153"
],
[
"8251343892709140154567051772980662609566359215743613773155065627504813327653",
"22035238365102171608166944627493632660244312563934708756134297161332908879090",
"13560937766273321037807329177749403409731524715067067740487246745322577571823"
],
[
"21652518608959234550262559135285358020552897349934571164032339186996805408040",
"22479086963324173427634460342145551255011746993910136574926173581069603086891",
"13676501958531751140966255121288182631772843001727158043704693838707387130095"
],
[
"5680310394102577950568930199056707827608275306479994663197187031893244826674",
"25125360450906166639190392763071557410047335755341060350879819485506243289998",
"22659254028501616785029594492374243581602744364859762239504348429834224676676"
],
[
"23101411405087512171421838856759448177512679869882987631073569441496722536782",
"24149774013240355952057123660656464942409328637280437515964899830988178868108",
"5782097512368226173095183217893826020351125522160843964147125728530147423065"
],
[
"13540762114500083869920564649399977644344247485313990448129838910231204868111",
"20421637734328811337527547703833013277831804985438407401987624070721139913982",
"7742664118615900772129122541139124149525273579639574972380600206383923500701"
],
[
"1109643801053963021778418773196543643970146666329661268825691230294798976318",
"16580663920817053843121063692728699890952505074386761779275436996241901223840",
"14638514680222429058240285918830106208025229459346033470787111294847121792366"
],
[
"17080385857812672649489217965285727739557573467014392822992021264701563205891",
"26176268111736737558502775993925696791974738793095023824029827577569530708665",
"4382756253392449071896813428140986330161215829425086284611219278674857536001"
],
[
"13934033814940585315406666445960471293638427404971553891617533231178815348902",
"27054912732979753314774418228399230433963143177662848084045249524271046173121",
"28916070403698593376490976676534962592542013020010643734621202484860041243391"
],
[
"24820015636966360150164458094894587765384135259446295278101998130934963922381",
"7969535238488580655870884015145760954416088335296905520306227531221721881868",
"7690547696740080985104189563436871930607055124031711216224219523236060212249"
],
[
"9712576468091272384496248353414290908377825697488757134833205246106605867289",
"12148698031438398980683630141370402088785182722473169207262735228500190477924",
"14359657643133476969781351728574842164124292705609900285041476162075031948227"
],
[
"23563839965372067275137992801035780013422228997724286060975035719045352435470",
"4184634822776323233231956802962638484057536837393405750680645555481330909086",
"16249511905185772125762038789038193114431085603985079639889795722501216492487"
],
[
"11001863048692031559800673473526311616702863826063550559568315794438941516621",
"4702354107983530219070178410740869035350641284373933887080161024348425080464",
"23751680507533064238793742311430343910720206725883441625894258483004979501613"
],
[
"28670526516158451470169873496541739545860177757793329093045522432279094518766",
"3568312993091537758218792253361873752799472566055209125947589819564395417072",
"1819755756343439646550062754332039103654718693246396323207323333948654200950"
],
[
"5372129954699791301953948907349887257752247843844511069896766784624930478273",
"17512156688034945920605615850550150476471921176481039715733979181538491476080",
"25777105342317622165159064911913148785971147228777677435200128966844208883059"
],
[
"25350392006158741749134238306326265756085455157012701586003300872637887157982",
"20096724945283767296886159120145376967480397366990493578897615204296873954844",
"8063283381910110762785892100479219642751540456251198202214433355775540036851"
],
[
"4393613870462297385565277757207010824900723217720226130342463666351557475823",
"9874972555132910032057499689351411450892722671352476280351715757363137891038",
"23590926474329902351439438151596866311245682682435235170001347511997242904868"
],
[
"17723373371137275859467518615551278584842947963894791032296774955869958211070",
"2350345015303336966039836492267992193191479606566494799781846958620636621159",
"27755207882790211140683010581856487965587066971982625511152297537534623405016"
],
[
"6584607987789185408123601849106260907671314994378225066806060862710814193906",
"609759108847171587253578490536519506369136135254150754300671591987320319770",
"28435187585965602110074342250910608316032945187476441868666714022529803033083"
],
[
"16016664911651770663938916450245705908287192964254704641717751103464322455303",
"17551273293154696089066968171579395800922204266630874071186322718903959339163",
"20414195497994754529479032467015716938594722029047207834858832838081413050198"
],
[
"19773307918850685463180290966774465805537520595602496529624568184993487593855",
"24598603838812162820757838364185126333280131847747737533989799467867231166980",
"11040972566103463398651864390163813377135738019556270484707889323659789290225"
],
[
"5189242080957784038860188184443287562488963023922086723850863987437818393811",
"1435203288979376557721239239445613396009633263160237764653161500252258220144",
"13066591163578079667911016543985168493088721636164837520689376346534152547210"
],
[
"17345901407013599418148210465150865782628422047458024807490502489711252831342",
"22139633362249671900128029132387275539363684188353969065288495002671733200348",
"1061056418502836172283188490483332922126033656372467737207927075184389487061"
],
[
"10241738906190857416046229928455551829189196941239601756375665129874835232299",
"27808033332417845112292408673209999320983657696373938259351951416571545364415",
"18820154989873674261497645724903918046694142479240549687085662625471577737140"
],
[
"7983688435214640842673294735439196010654951226956101271763849527529940619307",
"17067928657801807648925755556866676899145460770352731818062909643149568271566",
"24472070825156236829515738091791182856425635433388202153358580534810244942762"
],
[
"25752201169361795911258625731016717414310986450004737514595241038036936283227",
"26041505376284666160132119888949817249574689146924196064963008712979256107535",
"23977050489096115210391718599021827780049209314283111721864956071820102846008"
],
[
"26678257097278788410676026718736087312816016749016738933942134600725962413805",
"10480026985951498884090911619636977502506079971893083605102044931823547311729",
"21126631300593007055117122830961273871167754554670317425822083333557535463396"
],
[
"1564862894215434177641156287699106659379648851457681469848362532131406827573",
"13247162472821152334486419054854847522301612781818744556576865965657773174584",
"8673615954922496961704442777870253767001276027366984739283715623634850885984"
],
[
"2794525076937490807476666942602262298677291735723129868457629508555429470085",
"4656175953888995612264371467596648522808911819700660048695373348629527757049",
"23221574237857660318443567292601561932489621919104226163978909845174616477329"
],
[
"1878392460078272317716114458784636517603142716091316893054365153068227117145",
"2370412714505757731457251173604396662292063533194555369091306667486647634097",
"17409784861870189930766639925394191888667317762328427589153989811980152373276"
],
[
"25869136641898166514111941708608048269584233242773814014385564101168774293194",
"11361209360311194794795494027949518465383235799633128250259863567683341091323",
"14913258820718821235077379851098720071902170702113538811112331615559409988569"
],
[
"12957012022018304419868287033513141736995211906682903915897515954290678373899",
"17128889547450684566010972445328859295804027707361763477802050112063630550300",
"23329219085372232771288306767242735245018143857623151155581182779769305489903"
],
[
"1607741027962933685476527275858938699728586794398382348454736018784568853937",
"2611953825405141009309433982109911976923326848135736099261873796908057448476",
"7372230383134982628913227482618052530364724821976589156840317933676130378411"
],
[
"20203606758501212620842735123770014952499754751430660463060696990317556818571",
"4678361398979174017885631008335559529633853759463947250620930343087749944307",
"27176462634198471376002287271754121925750749676999036165457559387195124025594"
],
[
"6361981813552614697928697527332318530502852015189048838072565811230204474643",
"13815234633287489023151647353581705241145927054858922281829444557905946323248",
"10888828634279127981352133512429657747610298502219125571406085952954136470354"
]
],
fullRounds: 55,
partialRounds: 0,
hasInitialRoundConstant: false,
stateSize: 3,
rate: 2,
power: 7
};
var poseidonParamsLegacyFp = {
mds: [
[
"5328350144166205084223774245058198666309664348635459768305312917086056785354",
"15214731724107930304595906373487084110291887262136882623959435918484004667388",
"22399519358931858664262538157042328690232277435337286643350379269028878354609"
],
[
"10086628405675314879458652402278736459294354590428582803795166650930540770072",
"17127968360683744052278857147989507037142007029142438136689352416106177192235",
"14207324749280135281015658576564097509614634975132487654324863824516044294735"
],
[
"3059104278162906687184746935153057867173086006783171716838577369156969739687",
"16755849208683706534025643823697988418063305979108082130624352443958404325985",
"16889774624482628108075965871448623911656600744832339664842346756371603433407"
]
],
roundConstants: [
[
"1346081094044643970582493287085428191977688221215786919106342366360741041016",
"10635969173348128974923358283368657934408577270968219574411363948927109531877",
"18431955373344919956072236142080066866861234899777299873162413437379924987003"
],
[
"5797044060651575840084283729791357462720161727701814038830889113712361837236",
"931288489507796144596974766082847744938192694315568692730730202141894005205",
"13659894470945121760517769979107966886673294523737498361566285362771110125394"
],
[
"6076231707445968054305995680347976771585015308155855387339303513025362636128",
"28822740034050339685362260108484262889265034407340240070058997651710236456303",
"23420266473857869790486107029614186913447272961845992963194006142267563993493"
],
[
"13753917374184785903125509246122783296344288469304898921025291716613575849357",
"22396739346703340038555577564698139382745239004673153148674304627904081092826",
"13064238335532551154986111986409392866270911640785653458047811526842088084911"
],
[
"23165923875642452719095776619341762858050322341374771345641255745672274104746",
"1876216571769482372914291210815859835162659440705283782713345335434924136736",
"25448252060136178247213604035267580231762596830634036926922217427938159849142"
],
[
"2161875315509206970842862195937323600322108268401381254431163181777726747153",
"19159855698625842998331760283165907305622417625829203038229273729196960321630",
"24828563875172432296791053766778475681869974948122169083176331088266823626561"
],
[
"15959479662608710141128458274961057999257961784282074767105536637788386907463",
"8006369581283017287449277389162056290714176164680299906116833200510117952858",
"18794336794618132129607701188430371953320538976527988886453665523008714542779"
],
[
"19408271715954593722501381885401160867835377473312521553027032015227895029571",
"13654747284005184272412579731446984220568337794941823533879059135026064413631",
"14094055032353750931629930778481002727722804310855727808905931659115939920989"
],
[
"13241818625838429282823260827177433104574315653706102174619924764342778921524",
"25709259239494174564705048436260891089407557689981668111890003079561388887725",
"26866626910239634723971078462134580196819809568632305020800296809092442642381"
],
[
"23886826350713085163238005260075062110062681905356997481925492650252417143049",
"16853602711255261520713463306790360324679500458440235992292027384928526778856",
"18444710386168488194610417945072711530390091945738595259171890487504771614189"
],
[
"16896789009769903615328691751424474161656500693270070895928499575572871141439",
"23842266984616972287898037872537536999393060934879414668030219493005225085992",
"24369698563802298585444760814856330583118549706483939267059237951238240608187"
],
[
"25360195173713628054110426524260405937218170863260484655473435413697869858790",
"1486437708678506228822038923353468635394979165769861487132708983207562337116",
"18653498960429911228442559598959970807723487073275324556015861725806677047150"
],
[
"18878179044241268037057256060083772636369783391816038647949347814518015576522",
"178715779905629247116805974152863592571182389085419970371289655361443016848",
"8381006794425876451998903949255801618132578446062133243427381291481465852184"
],
[
"4176946262813877719206528849579392120806054050640974718891398605746592169324",
"16376345520728802444699629729684297833862527190772376028981704525651968727081",
"8399065769082251057361366626601550736334213197703006866551331927128775757919"
],
[
"15435308585611812393531506745122614542196708285088622615406141986333182280857",
"4082259282787276939431186930090898350392871145699460879678141552997816391817",
"26348742719959309014730178326877937464605873211235784184917342950648457078699"
],
[
"9707631711734344681918469569872517425107158187591261754498805460753455298868",
"27910768846011709391567916011595957279088224137468948238696800459136335473132",
"20407239095656434708569263842372155762970847207558227886302782130015730063802"
],
[
"22726225412881182965250630589245572283256255052470345984553083359461473893802",
"12443967854426795490638709950679156338200426963050610832781263082981525248175",
"27102543658848146076219989119639465430524061997280788166887046421706499775415"
],
[
"14427224233985680214097547669945064793149553513421479297921556194475574770861",
"22917454832925781549840198815703114840452733537799472739275668965081704937832",
"3455076056123630366063931123762198941796412458154689469887583689725886013901"
],
[
"4513100023937785913596662867311227004762025658663076805918211014066645403017",
"18187619530784075723418065322038024507729605774832001333883311123910954334059",
"9447065431426150382325592560406989926365684509675374414068135115024495130938"
],
[
"3227816098015819796753427754968234889554095489076864339942014527747604603014",
"14798316759185072116520458171957899889489461918408669809912344751222514418582",
"23013904852315603905843158448056763116188801262838729536210355401378476650033"
],
[
"20979191509934291452182967564058656088941447895799901211038858159903580333267",
"20772973010251235271448378823573767262405703078344288856168565499702414379868",
"10105446427739226002497411811738001382334316505480517822035303561899927603685"
],
[
"11079074761356717003579108002319997196881121172538617046865136940931215263187",
"4693927775411489288330326150094711670434597808961717172753867514688725690438",
"18581720304902876944842830383273503265470859268712618325357902881821721540119"
],
[
"3065369948183164725765083504606321683481629263177690053939474679689088169185",
"18515622379147081456114962668688706121098539582467584736624699157043365677487",
"17563088600719312877716085528177751048248154461245613291986010180187238198006"
],
[
"26199746176994924146211004840756471702409132230831594954444947705902602287290",
"7576136600627345523051497639367002272003104458453478964661395239732811642605",
"20058687874612168338994287374025378897088936171250328231848098497610185784281"
],
[
"16894722532414195606958290526999761110785277556463400588047573469106594850228",
"13961730805696859614283621225672002906734926278118993580398533742874863598733",
"25256842011135514243352951950573936602906198374305137963222382546140030647211"
],
[
"18530360047537856737482157200091774590035773602620205695980247565433703032532",
"23014819965938599260086897799541446473887833964178378497976832161473586995397",
"27911426213258307990762460361663504655967992659180759140364181941291843542489"
],
[
"1067338118323302017358103178057182291035336430305886255160210378977812067042",
"17219092885519007424608854460610388434712113621163885775309496940189894433620",
"16432921127615937542183846559291144733339643093361323334499888895135356545408"
],
[
"28608851042959977114787048070153637607786033079364369200270218128830983558707",
"10121629780013165888398831090128011045011860641816380162950736555305748332191",
"2348036340843128746981122630521268144839343500596932561106759754644596320722"
],
[
"16619881370356823200358060093334065394764987467483650323706184068451904156452",
"2302436627861989749837563733434625231689351276818486757748445924305258835336",
"27514536540953539473280001431110316405453388911725550380123851609652679788049"
],
[
"9459277727420672604737117687200019308525004979918488827092207438664125039815",
"23425670740358068509956137586663046763224562225383386726193078231034380596217",
"7641885067011661443791509688937280323563328029517832788240965464798835873658"
],
[
"9579420382351699601929202663836555665702024548386778299996961509578687980280",
"18513671386572584282611234979588379470994484682444053600751415262497237017703",
"24923151431234706142737221165378041700050312199585085101919834422744926421604"
],
[
"21131320841803068139502705966375283830095161079635803028011171241658723560073",
"19208476595309656066589572658712717685014329237892885950958199953675225096566",
"24023185216737416080949689106968568821656545490748664446389634158498624398204"
],
[
"7510552996848634969347937904645640209946785877619890235458182993413526028718",
"3694415017252995094553868781762548289196990492336482360084813900937464847638",
"9219021070107873028263141554048987416559034633883158827414043929220388719352"
],
[
"5058327241234443421111591959922712922949620710493120384930391763032694640881",
"13148252221647574076185511663661016015859769210867362839817254885265598775418",
"15186790492457240277904880519227706403545816456632095870015828239411033220638"
],
[
"2775942914650502409705888572245750999561427024488403026572311267798009048466"