added basic CLI, read from buffer