Go to file
Emmanuel T Odeke 97bdad8262 common: NewBitArray never crashes on negatives (#170)
Fixes #169
Fixes https://github.com/tendermint/tendermint/issues/1322

The previous code was very trusting assuming that
rational actors will use this code. However, Byzantine
actors don't care and in the case of the linked issue
negative lengths can be sent to this code unfettered
having been received from a peer.

This code is essentially just a sign change from
`==`
to
`<=`

and we've gutted out that attack by being more defensive.
2018-03-22 19:36:24 -04:00
autofile fix metalinter errors 2017-10-30 13:01:18 -05:00
cli cli: WriteDemoConfig -> WriteConfigVals 2018-02-02 23:05:28 -05:00
clist add waitCh as an alternative to waitGroup 2018-02-05 11:36:36 +04:00
common common: NewBitArray never crashes on negatives (#170) 2018-03-22 19:36:24 -04:00
db DbBackend -> DBBackend 2018-02-02 22:31:17 -05:00
events change service#Start to return just error (Refs #45) 2017-11-06 12:18:04 -05:00
flowrate linting: add to Makefile & do some fixes 2017-09-22 11:42:29 -04:00
log Merge pull request #77 from tendermint/18-unsupported-value-type 2017-11-07 21:29:54 -05:00
merkle merkle: remove go-wire dep by copying EncodeByteSlice 2018-02-03 01:29:39 -05:00
pubsub return error if client already subscribed 2017-12-09 23:35:14 -06:00
test go-common -> tmlibs 2017-04-18 17:56:05 -04:00
version version bump and changelog 2018-02-19 17:05:36 -05:00
.editorconfig add .editorconfig 2017-11-11 11:25:30 -05:00
.gitignore CacheDB (#67) 2017-11-09 17:42:32 -05:00
CHANGELOG.md changelog date 2018-02-20 22:00:20 -05:00
CODEOWNERS add codeowners file [ci skip] 2017-10-11 12:48:05 +04:00
Gopkg.lock Switch to dep from glide (#155) 2018-02-27 16:01:49 +04:00
Gopkg.toml Switch to dep from glide (#155) 2018-02-27 16:01:49 +04:00
LICENSE update license and changelog 2017-12-06 02:05:57 -05:00
Makefile Switch to dep from glide (#155) 2018-02-27 16:01:49 +04:00
README.md logger is deprecated, removed; closes #115 2017-12-29 16:25:15 +00:00
circle.yml circle 2018-01-02 10:53:56 -05:00
glide.lock Fix RepeatTimer memory leak (#137) 2018-02-09 13:31:32 +04:00
glide.yaml Fix RepeatTimer memory leak (#137) 2018-02-09 13:31:32 +04:00
merge.sh go-common -> tmlibs 2017-04-18 17:56:05 -04:00
test.sh drop metalinter 2017-12-29 10:42:02 -05:00

README.md

TMLIBS

This repo is a home for various small packages.

autofile

Autofile is file access with automatic log rotation. A group of files is maintained and rotation happens when the leading file gets too big. Provides a reader for reading from the file group.

cli

CLI wraps the cobra and viper packages and handles some common elements of building a CLI like flags and env vars for the home directory and the logger.

clist

Clist provides a linekd list that is safe for concurrent access by many readers.

common

Common provides a hodgepodge of useful functions.

db

DB provides a database interface and a number of implementions, including ones using an in-memory map, the filesystem directory structure, an implemention of LevelDB in Go, and the official LevelDB in C.

events

Events is a synchronous PubSub package.

flowrate

Flowrate is a fork of https://github.com/mxk/go-flowrate that added a SetREMA method.

log

Log is a log package structured around key-value pairs that allows logging level to be set differently for different keys.

merkle

Merkle provides a simple static merkle tree and corresponding proofs.

process

Process is a simple utility for spawning OS processes.

pubsub

PubSub is an asynchronous PubSub package.