Interplane page as plain text, for reading tools and agents. English is the reference text: translate it with your own tool. Text in backticks and in ``` blocks (commands, fingerprints, file names) and link targets in <...> are exact: copy them, never translate them. Page: /drakestapleton/omega-mv/blob/main/om/tls/test/ec/wolfram.txt # omega-mv Omega: a language for verified programs, semantic identity and machine realization. Seed-born work and existing implementations have distinct provenance. Brought by drakestapleton Sign in to star 1 stars 0 watching About Files History Releases Proposed changes Issues For developers branch `main` Branches Tags History `omega-mv / om / tls / test / ec / wolfram.txt` 35 lines ยท 4191 bytes Raw Blame History 1 Curve parameter check for om/tls/ec.om (2026-10-26, Wolfram MCP tool WolframLanguageEvaluator). 2 p, n, b, Gx, Gy are taken verbatim from FIPS 186-4 Appendix D.1.2.3 (P-256) and D.1.2.4 (P-384), 3 equal to SEC 2 v2 sections 2.4.2 (secp256r1) and 2.5.1 (secp384r1), and to 4 `openssl ecparam -name prime256v1|secp384r1 -param_enc explicit -text`. Montgomery constants 5 (n0' = -m^-1 mod 2^32, R mod m, R^2 mod m) are not stored: ec_ctx computes them at run time. 6 7 Query (exact code sent): 8 chk[p_,b_,gx_,gy_,n_]:=Module[{add,mul},add[P_,Q_]:=Which[P===0,Q,Q===0,P,Mod[P[[1]]-Q[[1]],p]==0&&Mod[P[[2]]+Q[[2]],p]==0,0,True,Module[{l=If[P===Q,Mod[(3P[[1]]^2-3)PowerMod[2P[[2]],-1,p],p],Mod[(Q[[2]]-P[[2]])PowerMod[Q[[1]]-P[[1]],-1,p],p]],x3},x3=Mod[l^2-P[[1]]-Q[[1]],p];{x3,Mod[l(P[[1]]-x3)-P[[2]],p]}]];mul[k_,P_]:=Module[{R=0,A=P,kk=k},While[kk>0,If[OddQ[kk],R=add[R,A]];A=add[A,A];kk=Quotient[kk,2]];R];{PrimeQ[p],PrimeQ[n],Mod[gy^2-(gx^3-3gx+b),p]==0,mul[n,{gx,gy}]===0,BitLength[p],BitLength[n],n