On Sun, Aug 19, 2018 at 05:16:58PM +0000, Asbjørn Sloth Tønnesen wrote: > When script is used to log usage of shell accounts, accessible by > random users (some of whom might be malicious). > > This patch adds a new --input-log option, which makes script save > the input data to a file, in an extended timing format also containing > the data, thereby allowing the input to be reconstructed. I like the feature, but not sure if we really need to introduce a new log format specific to the input stream. For long time I think about a new timing file format. Maybe we can add support for new timing file format where will be possible log information about more streams (stdin and stdout) and events (for example signals). In this case we can for stdin use the same concept like for stdout -- it means raw file with data. The final result will be three files: - stdout (raw, without formatting) - stdin (raw, without formatting) - timing (<type> <timestampts> [<offset> , misc...]) where type = S, I or O (signal, input or output) timestampts = timing info type specific information: offset = offset in bytes to the log (stream) file (O or I type) signal = signal name for S type ..etc. It would be also nice to have info about version, format in the timing file header. And new options like: --timing-format <classic,new> --recording <stdin,stdout,signals,...> --stdout-log <filename> --stdin-log <filename> The default should be backwardly compatible (old format, stdout-only, etc.) Karel -- Karel Zak <kzak@xxxxxxxxxx> http://karelzak.blogspot.com