improved docs and license headers, adding direct access protection