from https://github.com/alt-project/foocoin-origin