CodeAnt AI home pagelight logodark logo
  • Support
  • Dashboard
  • Dashboard
Documentation
API Reference
  • Join Community
Start Here
  • What is CodeAnt?
Setup
  • Github
  • Bitbucket
  • Gitlab
  • Azure Devops
Pull Request Review
  • Features
  • Customize Review
  • Quality Gates
  • Integrations
Scan center
  • Code Security
  • Code Quality
  • Cloud Security
  • Engineering Productivity
Integrations
  • Jira
  • Test Coverage
  • CI/CD
IDE
  • Setup
  • Review
  • Enhancements
Rule Reference
  • Compliance
  • Anti-Patterns
  • Code Governance
  • Infrastructure Security Database
  • Application Security Database
    • Apex
    • Bash
    • C
    • Clojure
    • Cpp
    • Csharp
    • Dockerfile
    • Elixir
    • Fingerprints
    • Generic
    • Go
    • Html
    • Java
    • Javascript
    • Json
    • Kotlin
    • Ocaml
    • Php
      • Doctrine
      • Lang
      • Laravel
        • Security
        • Security
          • Laravel-code-injection
          • Laravel-column-sql-injection
          • Laravel-command-injection
          • Laravel-cookie-not-encrypted
          • Laravel-csrf-not-verified
          • Laravel-direct-response-write
          • Laravel-http-client-ssrf
          • Laravel-mail-command-injection
          • Laravel-native-sql-injection
          • Laravel-path-traversal-storage
          • Laravel-path-traversal
            • Laravel path traversal
          • Laravel-raw-sql-injection
          • Laravel-unsafe-entity-loader
          • Laravel-xml-unsafe-parser-flags
          • Search-laravel-form-csrf
      • Secrets
      • Symfony
      • Wordpress-plugins
    • Problem-based-packs
    • Python
    • Ruby
    • Rust
    • Scala
    • Solidity
    • Swift
    • Terraform
    • Typescript
    • Yaml
Resources
  • Open Source
  • Blogs
Laravel-path-traversal

Laravel path traversal

laravel-path-traversal

The application builds a file path from potentially untrusted data, which can lead to a path traversal vulnerability. An attacker can manipulate the file path which the application uses to access files. If the application does not validate user input and sanitize file paths, sensitive files such as configuration or user data can be accessed, potentially creating or overwriting files. In PHP, this can lead to both local file inclusion (LFI) or remote file inclusion (RFI) if user input reaches this statement. To prevent this vulnerability, validate and sanitize any input that is used to create references to file paths. Also, enforce strict file access controls. For example, choose privileges allowing public-facing applications to access only the required files.
Likelihood: LOW
Confidence: MEDIUM
CWE:
- CWE-22: Improper Limitation of a Pathname to a Restricted Directory (‘Path Traversal’)
OWASP:
- A06:2017 - Security Misconfiguration
- A05:2021 - Security Misconfiguration
Laravel path traversal storageLaravel raw sql injection
twitterlinkedin
Powered by Mintlify
Assistant
Responses are generated using AI and may contain mistakes.