Skip to content

Conversation

@yashuatla
Copy link
Owner

@yashuatla yashuatla commented Jun 25, 2025

PR Summary

Refactor Galois Field Operations and Update Import Structure

Overview

This PR completely rewrites the Galois Field GF(2^8) arithmetic operations for Shamir's Secret Sharing algorithm and reorganizes import statements in the keysource file.

Change Types

Type Description
Refactor Complete rewrite of Galois Field arithmetic operations
Enhancement Addition of new inverse function for Shamir's Secret Sharing
Refactor Reorganization of import statements

Affected Modules

Module / File Change Description
shamir.go Complete rewrite of GF(2^8) arithmetic operations (div, mult, add) and addition of new inverse function
keysource.go Reorganized imports and added new dependencies (os/exec, github.com/google/shlex)

Notes for Reviewers

  • The Galois Field operations have been completely rewritten - please verify mathematical correctness
  • New dependencies have been added to keysource.go - ensure they are necessary and properly used

cgetzen and others added 18 commits July 31, 2024 17:02
Signed-off-by: Charlie Getzen <charlie_g@regrello.com>
Signed-off-by: Danilo Bürger <danilo.buerger@helsing.ai>
Signed-off-by: Danilo Bürger <danilo.buerger@helsing.ai>
…nfig

chore: omitempty metadata to reduce the size of stored config
Signed-off-by: Felix Fontein <felix@fontein.de>
This isn't useful for SOPS (see removed comment), and thus only
adds unnecessary complexity. Basically un-does
hashicorp/vault@b4602fc

Signed-off-by: Felix Fontein <felix@fontein.de>
Copied from
hashicorp/vault@9510adc.
Please note that Vault at that point in history did not change the license yet,
so using that commit is fine.

Signed-off-by: Felix Fontein <felix@fontein.de>
Copied from
hashicorp/vault@ed08e45
Please note that Vault at that point in history did not change the license yet,
so using that commit is fine.

Signed-off-by: Felix Fontein <felix@fontein.de>
… is zero.

Signed-off-by: Felix Fontein <felix@fontein.de>
While writing these comments I noticed that OpenBao added similar
comments roughly a year ago:
openbao/openbao@a209a05

Signed-off-by: Felix Fontein <felix@fontein.de>
Signed-off-by: Felix Fontein <felix@fontein.de>
Improve Shamir Secret Sharing code
Signed-off-by: Felix Fontein <felix@fontein.de>
Signed-off-by: Felix Fontein <felix@fontein.de>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants