Javascript implementation of the opencoin protocol