seclog icon indicating copy to clipboard operation
seclog copied to clipboard

old log file permission mode should be read-only for security?

Open chenwei113524 opened this issue 3 years ago • 4 comments

when log file is rotated, the log file new the same permission mode w+r. the history log file should change to a read-only mode or allow to set file mode?

chenwei113524 avatar Dec 23 '21 08:12 chenwei113524

great idea, would u like to contribute this feature

tianxiaoliang avatar Dec 23 '21 08:12 tianxiaoliang

可以弄个定时任务,定时修改rotate日志权限吗?我看service-center 1.2.0 是这样处理rotate日志 image

chenwei113524 avatar Dec 24 '21 07:12 chenwei113524

rotate是有lumberjack这个三方库提供的,看看修改点在哪里,如果lumberjack有参数可配置就更好了,或许我们只是没发现这个参数。

tianxiaoliang avatar Apr 19 '22 07:04 tianxiaoliang

rotate是有lumberjack这个三方库提供的,看看修改点在哪里,如果lumberjack有参数可配置就更好了,或许我们只是没发现这个参数。

假如没这个参数,我建议在lumberjack找到这个修改点,贡献这个开源库

tianxiaoliang avatar Apr 19 '22 07:04 tianxiaoliang