Skip to content

Instantly share code, notes, and snippets.

Adam Langley agl

Block or report user

Report or block agl

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
@agl
agl / webauthnRegistrationOptions.hs
Created Sep 12, 2019
WebAuthn Registration Options classification
View webauthnRegistrationOptions.hs
data Attachment = NoAttachment | Platform | CrossPlatform deriving (Show)
data ResidentKey = RKNotSpecified | RKDiscouraged | RKPreferred | RKRequired deriving (Show)
data UserVerification = UVDiscouraged | UVPreferred | UVRequired deriving (Show)
allCreateOptions = do
attachment <- [NoAttachment, Platform, CrossPlatform]
rk <- [RKNotSpecified, RKDiscouraged, RKPreferred, RKRequired]
uv <- [UVDiscouraged, UVPreferred, UVRequired]
return (attachment, rk, uv)
View keybase.md

Keybase proof

I hereby claim:

  • I am agl on github.
  • I am agl (https://keybase.io/agl) on keybase.
  • I have a public key whose fingerprint is C921 7238 4F38 7DBA ED4D 4201 65EB 9636 F02C 5704

To claim this, I am signing this object:

View dummy-https-proxy.go
package main
import (
"crypto/tls"
"fmt"
"net"
"os"
"bytes"
"io"
)
View otr.patch
diff --git a/otr/otr.go b/otr/otr.go
index 0d18a60..ed560ed 100644
--- a/otr/otr.go
+++ b/otr/otr.go
@@ -12,20 +12,21 @@ import (
"crypto/cipher"
"crypto/dsa"
"crypto/hmac"
"crypto/rand"
"crypto/sha1"
@agl
agl / test1.v
Created Oct 4, 2014
VST forward issue (VST 1.5, Coq 8.4p4, CompCert 2.4)
View test1.v
Require Import Clightdefs.
Require Import floyd.proofauto.
Require Import Coq.ZArith.Zdiv.
Require Import compcert.common.Values.
Local Open Scope Z_scope.
Definition _b : ident := 32%positive.
Definition ___compcert_va_int64 : ident := 16%positive.
Definition ___builtin_fmadd : ident := 24%positive.
@agl
agl / gist:aac39429601667c588cc
Created Oct 4, 2014
1024-bit key, generated with OpenSSL, for purported factorisation.
View gist:aac39429601667c588cc
If anyone can publish the two, non-trivial factors of this number (where neither is 1!) then they'll have my attention:
0xe5c30e1286c41c7137dc06194199dde641120de591c1b7392de35ef6a961d6d29faa3bcdb7603d42768a90322197a7a46fa2cf23f6f10de5554db6e7322ba35e858f576f840347c795c8782c3f4ef9f530d2fd1f6b5c275ce49404958f0decddd0b53386d12c745891d5eeca1f265bdf87bfe258cc7999dd1b21c570dddf1b33
In standard form:
-----BEGIN PUBLIC KEY-----
MIGfMA0GCSqGSIb3DQEBAQUAA4GNADCBiQKBgQDlww4ShsQccTfcBhlBmd3mQRIN
5ZHBtzkt4172qWHW0p+qO823YD1CdoqQMiGXp6Rvos8j9vEN5VVNtucyK6NehY9X
b4QDR8eVyHgsP0759TDS/R9rXCdc5JQElY8N7N3QtTOG0Sx0WJHV7sofJlvfh7/i
@agl
agl / test.c
Created Sep 13, 2014
VST forward issue.
View test.c
#include <stdint.h>
typedef int64_t limb;
typedef int32_t s32;
void product(limb out[19], const limb *a, const limb *b) {
s32 t1, t2;
t1 = a[0];
t2 = b[0];
View cacerts.go
package main
import (
"crypto/x509"
"fmt"
"io/ioutil"
"sync"
"strconv"
)
@agl
agl / gen.go
Created Apr 15, 2012
GPG/X.509 certificates
View gen.go
package main
import (
"bytes"
"code.google.com/p/go.crypto/openpgp"
"crypto/rand"
"crypto/rsa"
"crypto/x509/pkix"
"encoding/pem"
"fmt"
@agl
agl / gist:876829
Created Mar 18, 2011
Proxy server for testing revocation
View gist:876829
package main
import (
"bufio"
"fmt"
"io"
"net"
"strings"
)
You can’t perform that action at this time.