Skip to content

feat: Added Kolmar cipher operation#2657

Open
1mpuser wants to merge 2 commits into
gchq:masterfrom
1mpuser:add-kolmar-cipher
Open

feat: Added Kolmar cipher operation#2657
1mpuser wants to merge 2 commits into
gchq:masterfrom
1mpuser:add-kolmar-cipher

Conversation

@1mpuser

@1mpuser 1mpuser commented Jul 10, 2026

Copy link
Copy Markdown

Description
Adds a new operation, "Kolmar Cipher" (Encode/Decode), based on a custom Russian-language
substitution cipher originally created and published at kolmarchik.ru. The cipher derives a
grid of "boxes" from user-supplied Russian code word(s) (via syllable splitting and a digit-based
capacity rule per letter), then distributes the plaintext's Cyrillic letters into that grid in a
round-robin fill order, dynamically opening new rows as needed. Decode reverses the process to
recover the original letter sequence (spaces are not preserved, matching the original site's
behaviour).

Options added:

  • Code words (string)
  • Mode (Encode / Decode)

Existing Issue
N/A — this is not tied to an existing issue.

AI disclosure
I used Claude (Anthropic) to help port the algorithm into CyberChef's operation structure/
conventions (Operation class boilerplate, args config, following the pattern of existing cipher
operations like ROT13.mjs/VigenereEncode.mjs) and to help draft the test cases. The cipher
algorithm itself was not designed or written by AI — it's a pre-existing algorithm from
kolmarchik.ru, which I reverse-engineered/ported (with the original source's own JS as reference)
rather than having AI invent the cipher logic. I've reviewed the implementation myself and can
answer questions about how it works.

Test Coverage
Added tests in tests/operations/KolmarCipher.mjs covering: basic encode/decode round-trip,
manual syllable splitting via hyphen, multi-row/multi-codeword output, non-Cyrillic character
stripping, empty input, and missing code words on decode.

@CLAassistant

Copy link
Copy Markdown

CLA assistant check
Thank you for your submission! We really appreciate it. Like many open source projects, we ask that you sign our Contributor License Agreement before we can accept your contribution.


Alexei Baranov seems not to be a GitHub user. You need a GitHub account to be able to sign the CLA. If you have already a GitHub account, please add the email address used for this commit to your account.
You have signed the CLA already but the status is still pending? Let us recheck it.

@1mpuser 1mpuser changed the title "Add Kolmar cipher operation" feat: Added Kolmar cipher operation Jul 10, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants