Skip to content

Commit

Permalink
Make denies info, and bump autoconf logger to warning; #293
Browse files Browse the repository at this point in the history
  • Loading branch information
Xyene committed Dec 9, 2017
1 parent c4ea995 commit 32a41b7
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion dmoj/cptbox/chroot.py
Original file line number Diff line number Diff line change
Expand Up @@ -175,7 +175,7 @@ def check(debugger):
file = debugger.readstr(file_ptr)
if self._file_access_check(file, debugger, file_ptr):
return True
log.warning('Denied access via syscall %s: %s', syscall, file)
log.info('Denied access via syscall %s: %s', syscall, file)
return ACCESS_ENOENT(debugger)

return check
Expand Down
2 changes: 1 addition & 1 deletion dmoj/executors/autoconfig.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ def main():
silent = parser.parse_args().silent

if not silent:
logging.basicConfig(level=logging.INFO, format='%(message)s')
logging.basicConfig(level=logging.WARNING, format='%(message)s')

result = {}

Expand Down
4 changes: 2 additions & 2 deletions dmoj/executors/mono_executor.py
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ def get_security(self, launch_kwargs=None):
def handle_open(debugger):
file = debugger.readstr(debugger.uarg0)
if fs.match(file) is None:
log.warning('Denied file open: %s', file)
log.info('Denied file open: %s', file)
return ACCESS_ENOENT(debugger)
can = write_fs.match(file) is not None

Expand Down Expand Up @@ -93,7 +93,7 @@ def kill_return():
def unlink(debugger):
path = debugger.readstr(debugger.uarg0)
if UNLINK_FS.match(path) is None:
log.warning('Denied file unlink: %s', path)
log.info('Denied file unlink: %s', path)
return ACCESS_ENOENT(debugger)
return True

Expand Down

0 comments on commit 32a41b7

Please sign in to comment.