file: add exec method, rework read method