G0Bin is a client side encrypted pastebin written in Go
JavaScript HTML Go CSS
Latest commit b251919 Mar 28, 2016 @jyap808 Merge pull request #5 from gdm85/master
Make clone button work & other minor fixes
Permalink
Failed to load latest commit information.
pastes
static
templates Fixed clone feature Mar 28, 2016
.gitignore
LICENSE Initial commit Sep 30, 2013
README.md Server side handling of Max Size is now complete Feb 4, 2016
config.json Add option to hide file upload Feb 4, 2016
g0bin.go Do not succeed in case of paste save failure Mar 28, 2016

README.md

G0Bin

G0Bin is a client side encrypted pastebin. The server has zero knowledge of pasted data. Data is encrypted/decrypted in the browser using 256 bits AES.

DEMO: http://g0bin-demo.appspot.com

G0Bin is a Go port of 0bin (written in Python). 0bin in turn is an implementation of the ZeroBin project (written in PHP).

This project was created mostly as a Go learning exercise through converting a project I use often. It also serves as a great sample project in Go since it only uses the standard library.

Here are some elements that are have been implemented.

NOTE: The demo was modified to run on Google App Engine using the Datastore API.

How it works

When pasting a text into G0Bin:

Encryption image

  • You paste your text in the browser and click the “Submit” button.
  • A random 256 bits key is generated in the browser.
  • Data is compressed and encrypted with AES using Javascript libraries.
  • Encrypted data is sent to the server and stored.
  • The browser displays the final URL with the key.
  • The key is never transmitted to the server, which therefore cannot decrypt data.

When opening a G0Bin URL:

Decryption image

  • The browser requests encrypted data from the server
  • The decryption key is in the anchor part of the URL (#…) which is never sent to the server.
  • Data is decrypted in the browser using the key and displayed.

Install

Clone this repository, build it and run it.

git clone https://github.com/jyap808/g0bin.git
cd g0bin
go build
./g0bin

To run G0Bin on a different port, modify the Port setting in config.json.

The configuration of G0Bin can also be reloaded by sending a HUP signal to the process.

kill -HUP [PROCESS ID]

Other

This project modifies the Python implementation and cleans things up to make them more generic. It has the following changes:

  • Remove extra header links.
  • Remove extra link options.
  • Remove extra layout details.
  • Set Burn after reading as default option.

Here are some items which are in the Python implemention which have not been implemented.

  • Paste counter - Display a tiny counter for pastes created
  • Names/links to insert in the menu bar
  • Paste ID length
  • Clone paste

Copyright (c) 2016 Julian Yap

MIT License