AITemplate icon indicating copy to clipboard operation
AITemplate copied to clipboard

Ensure safe build dir name

Open kadeng opened this issue 1 year ago • 8 comments

Summary: In D44642328 we saw a test failure related to some test generating a test name which contains characters which might be unsafe for file or directory names ( e.g. curly brackets in that case ). In order to guard against such a thing, this diff introduces a small safety check in compile_model which assserts that the test_name argument contains only whitelisted characters ( english alphanumeric, underscore, dash, dot ) and that it is a nonempty string which is not one of the special directories "." or "..".

Differential Revision: D44867941

kadeng avatar Apr 11 '23 10:04 kadeng

This pull request was exported from Phabricator. Differential Revision: D44867941

facebook-github-bot avatar Apr 11 '23 10:04 facebook-github-bot

This pull request was exported from Phabricator. Differential Revision: D44867941

facebook-github-bot avatar Apr 11 '23 16:04 facebook-github-bot

This pull request was exported from Phabricator. Differential Revision: D44867941

facebook-github-bot avatar Apr 11 '23 16:04 facebook-github-bot

This pull request was exported from Phabricator. Differential Revision: D44867941

facebook-github-bot avatar Apr 11 '23 16:04 facebook-github-bot

This pull request was exported from Phabricator. Differential Revision: D44867941

facebook-github-bot avatar Apr 11 '23 16:04 facebook-github-bot

This pull request was exported from Phabricator. Differential Revision: D44867941

facebook-github-bot avatar Apr 11 '23 19:04 facebook-github-bot

This pull request was exported from Phabricator. Differential Revision: D44867941

facebook-github-bot avatar Apr 11 '23 20:04 facebook-github-bot

This pull request was exported from Phabricator. Differential Revision: D44867941

facebook-github-bot avatar Apr 12 '23 08:04 facebook-github-bot