Skip to content

v6.0.2

Compare
Choose a tag to compare
@Metachaser24 Metachaser24 released this 19 Apr 05:49
· 169 commits to main since this release

We are excited to announce the release of zk-email-verify v6..0.2 for our circuits, helpers and contracts packages. These updates improve our codebase, enhancing integration capabilities and usability. Please note, these are breaking changes that will affect all three packages, requiring updates for continued functionality.

What's Changed


@zk-email/circuits

Major Refactors: The EmailVerifier circuit has undergone a significant refactor with the intent of improving clarity and developer experience. Variable names have been made more descriptive to better reflect their functions.
(PR#185 PR#192) @saleel

EmailVerifier.circom - Changes in variable names:

  • in_padded -> emailHeader
  • in_len_padded_bytes -> emailHeaderLength
  • body_hash_idx -> bodyHashIndex
  • precomputed_sha -> precomputedSHA
  • in_body_padded -> emailBody
  • in_body_len_padded_bytes -> emailBodyLength
  • pubkey_hash -> pubkeyHash

RSA and SHA Circuit Updates:

  • rsa.circom and sha.circom moved to /lib
  • RSAVerify65537 renamed to RSAVerifier65537
  • basemessage input in RSAVerifier65537 changed to message.
  • In SHA circuits, in_padded and in_len_padded_bytes were changed to paddedIn and paddedInLength.

Repository Structure and Circuit Relocations:

  • Circuits like fp.circom, base64.circom, bigint.circom, and bigint-func.circom (renamed from bigint_func.circom) have been relocated to the lib folder.
  • General utilities related to array and packing has been move to /utils in appropriate files. Refer to #185 to see all changes.

@zk-email/helpers

Refactoring and Improvements (PR#189 by @saleel)

  • binaryFormat file renamed to binary-format.ts
  • shaHash renamed to sha-utils.ts
  • zkp.ts renamed to chunked-zkey.ts
  • input-helpers.ts renamed to input-generators.ts

DKIM Edge Case Handling: Fixed multiple DKIM edge cases .

  • Input Generation from Raw EML: Added functionality to generate verification inputs directly from raw .eml files.

  • Extended DKIM and Input Helper Tests: Introduced new tests focused on DKIM sanitization processes and the functionality of input helpers, ensuring that both new and existing features perform as expected.

  • Standardization of Codebase: Renaming of files and functions to standardize naming conventions

Improved DKIM Testing (PR#174 by @saleel):

  • Standardized DKIM Retrieval: Using a standard npm package to fetch DKIM records. It's good for reliable DKIM processing across different environments.
  • ARC Signature Handling: Handling emails with ARC signatures to maintain verification accuracy when DKIM checks fail.
  • Email Header Restoration: Implemented functionality to revert alterations made to email headers by forwarders, such as restoring 'X-Message-ID' back to 'Message-ID', preserving the authenticity of the original email.

Partial SHA Skipping for Enhanced Performance (PR#186 by @saleel):

  • Conditional SHA Computation: Enabled the skipping of partial SHA calculations when the ignoreBodyHashCheck is true.
  • Adjustable Body Parameters: Made email body parameters optional based on the ignoreBodyHashCheck setting.

@zk-email/contracts

Oz5 Compatibility Update (PR#190 by @Divide-By-0):

  • DKIM Registry Testing: Updated contracts for AA Compatibility. Added a new unit test for the DKIM registry and modified the DKIMRegistry interface to require an initializer for the owner upon setup.

Full Changelog