Skip to content

Instantly share code, notes, and snippets.

View atoponce's full-sized avatar
Crypto coffee

Aaron Toponce atoponce

Crypto coffee
View GitHub Profile
@atoponce
atoponce / chaocipher-test-vector.txt
Last active May 23, 2024 16:56
Chaocipher analysis
> const Chaocipher = require('./chaocipher.js')
undefined
> const left = "HXUCZVAMDSLKPEFJRIGTWOBNYQ"
undefined
> const right = "PTLNBQDEOYSFAVZKGJRIHWXUMC"
undefined
> const pt = "WELLDONEISBETTERTHANWELLSAID"
undefined
> const cipher = new Chaocipher(left, right)
undefined

I didn't hit my goal of 1:25, but I knew that was very likely out of reach. But 1:28 felt very much within grasp. First, some stats:

  • Overall: 66/2797
  • Male: 57/1178
  • Male 45-59: 3/137
  • Male Masters: 11/512

I got up at 3:30 in the morning to have two slices of toast and make 500 mL of coffee. I took 1,000 mg of acetaminophen before heading out the door to make sure it was in my system before starting the race. When I got to the start line about 6 AM, I had a full banana and called it good on nutrition. I had a Maurten 100 gel with me for mile 8 as a safety net.

I started the first 4.4 miles to the spillway with the 1:30 pacer. It's very flat so I knew if I stuck with him, provided my HR and power weren't going into Z4, I would be okay. That seemed to pay off. The goal was to average 6:50 for those first 4.4 miles, and I averaged 6:51. Right on target.

Paces running 10×3' intervals @ 5K-10K pace with 3' recovery between intervals on the same route.

Pace is min/km. Lower pace difference is better.

Interval 9/23 Pace 4/24 Pace Pace Diff
1 4:22 4:05 -0:17
2 4:20 3:59 -0:21
3 4:15 4:01 -0:14
4 4:16 3:53 -0:19
@atoponce
atoponce / trivium.js
Last active April 4, 2024 17:59
Trivium stream cipher with test vectors
"use strict"
/** Class representing the Trivium stream cipher. */
module.exports = class Trivium {
#state // Trivium 288-bit state.
#keystream // Trivium keystream.
/**
* Initialize Trivium with key and IV.
* @param {Uint8Array} key - An 8-bit array of 10 unsigned integers.
@atoponce
atoponce / k4.md
Last active May 24, 2024 13:46
No, ChatGPT didn't solve Kryptos 4

So you think ChatGPT solved K4? You're not the only one. First, here's the K4 ciphertext and clues:

                           OBKR
UOXOGHULBSOLIFBBWFLRVQQPRNGKSSO
TWTQSJQSSEKZZWATJKLUDIAWINFBNYP
VTTMZFPKWGDKZXTJCDIGKUHUAUEKCAR

Jim Sandborn, the creator of the sculpture and puzzle has given us clues, revealing that characters:

@atoponce
atoponce / oi.js
Last active January 8, 2024 23:59 — forked from PaulCapestany/oi.js
Dan Kaminsky's DefCon RNG challenge
#!/usr/bin/env node
/**
* Forked from https://gist.github.com/PaulCapestany/6148566. Changes:
* - Beautified code
* - NodeJS-specific (will not work in the browser)
* - Scope variables with let and const keywords
* - 256-bit RNG
* - Remove von Neumann debiasing
* - Remove byte assembly

10,000 seconds RE:

Zone HR RE Ratio
1 80 15 0.0015
1 85 17 0.0017
1 90 19 0.0019
1 95 22 0.0022
1 100 24 0.0024
1 105 26 0.0026
@atoponce
atoponce / strava-hr-to-re.txt
Last active August 28, 2023 00:56
10,000 seconds of constant HR data with its resulting Strava Relative Effort score
First column is HR, second column is RE for 10,000 seconds at that HR.
Header is formula from the lowest HR to the max HR in that segment wihout the intermediate points.
There are 7 separate jumps.
8x/15-83/3
==========
80: 15
85: 17
90: 19
95: 22
@atoponce
atoponce / bibliography.md
Created August 22, 2023 04:42
Bibliography of running power chronologically ordered
test_name ntup OptiHash SHA-256 urandom
diehard_birthdays 0 🟥 🟢 🟢
diehard_operm5 0 🟥 🟥 🟥
diehard_rank_32x32 0 🟥 🟥 🟥
diehard_rank_6x8 0 🟥 🟥 🟥
diehard_bitstream 0 🟥 🟥 🟥
diehard_opso 0 🟥 🟥 🟥
diehard_oqso 0 🟥 🟥 🟥
diehard_dna 0 🟥 🟢 🟥