dallbit Prompt & Skill

Auth & Authz Security Audit

Audits security flaws in token management, sessions, permissions, and password hashing.

Prompt Template

The more specific your inputs, the higher the quality of the output.

{{source_code}}

You are a cybersecurity auditor. Evaluate the provided Authentication and Authorization logic from a security perspective. ### Source Code if(user.role == 'admin') { grantAccess(); } ### Evaluation Areas 1. **Token Management**: Security of creation, storage, refresh, and revocation. 2. **Session Management**: Defense against hijacking or fixation attacks. 3. **Permission Validation**: Proper checks for resource access. 4. **Password Handling**: Adequacy of hashing algorithms and salting. ### Deliverables - Categorize vulnerabilities by risk level (High/Medium/Low) in a table. - Provide specific solutions and security reinforcement code for each issue.