Skip to content

Instantly share code, notes, and snippets.

Casey Marshall cmars

  • Cmars Technologies LLC
  • No simple highway
Block or report user

Report or block cmars

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
@cmars
cmars / CFSSL.md
Last active Aug 10, 2016
Loneliest keysigning party ever
View CFSSL.md
  1. Install cfssl and cfssljson commands from https://github.com/cloudflare/cfssl

  2. Create a CA

Make a file called ca.json, containing this:

{
    "key": {
        "algo": "rsa",
        "size": 2048
@cmars
cmars / show_cookies.py
Created Apr 20, 2016
Show ~/.go-cookies content without compromising authorization tokens
View show_cookies.py
#!/usr/bin/env python3
import base64
import json
import os
import sys
if __name__ == '__main__':
if sys.argv[1:]:
filename = sys.argv[1]
View rsa_bench
package bench
import (
"crypto/tls"
"crypto/x509"
"testing"
"time"
"github.com/juju/juju/cert"
gc "gopkg.in/check.v1"
@cmars
cmars / README.md
Last active Jan 19, 2016
Juju sockets proof-of-concept
View README.md

This is a proof of concept demonstrating local socket communication with Juju using generally available command line utilities and commands from a remote shell via 'juju ssh' or 'juju run'.

@cmars
cmars / main.go
Last active Aug 29, 2015
dependency engine example
View main.go
package main
import (
"fmt"
"os"
"time"
"github.com/juju/juju/worker"
"github.com/juju/juju/worker/dependency"
)
View saltyspitton.go
package main
import (
"crypto/rand"
"fmt"
"code.google.com/p/go.crypto/nacl/box"
)
type PublicKey struct {
View ecdsa_bench
package main
import (
"bytes"
"crypto/ecdsa"
"crypto/elliptic"
"crypto/rand"
"crypto/sha256"
"flag"
"fmt"
@cmars
cmars / juju-nuke
Created Jan 7, 2014
This "juju nuke" plugin will not only destroy-service, it will also destroy-machine --force all machines running units of that service. Normally, juju does not reuse machines when destroying and redeploying services. This is useful when you're debugging on an OpenStack or AWS and tired of leaking instances when redeploying. This script is called…
View juju-nuke
#!/usr/bin/env python
import json
import os
import sys
from subprocess import Popen, PIPE
def die(msg):
print >>sys.stderr, msg
You can’t perform that action at this time.