fix: API route security fixes (path traversal, auth, bare except)
- articles.py: Path traversal sanitization - optimizer_logs.py: Admin auth guard - platform_config.py: Admin auth guard - system.py: Path traversal whitelist - topic_config.py: Admin auth guard - topics.py: Minor fix Ultraworked with [Sisyphus](https://github.com/code-yeongyu/oh-my-openagent) Co-authored-by: Sisyphus <clio-agent@sisyphuslabs.ai>
This commit is contained in:
@@ -167,7 +167,7 @@ def create_topic(
|
||||
try:
|
||||
num = int(max_topic.id[1:]) + 1
|
||||
topic_id = f"T{num:03d}"
|
||||
except:
|
||||
except (ValueError, TypeError):
|
||||
topic_id = f"T{datetime.now().strftime('%m%d%H%M')}"
|
||||
else:
|
||||
topic_id = f"T{datetime.now().strftime('%m%d%H%M')}"
|
||||
|
||||
Reference in New Issue
Block a user