laravel-security

Enforce security best practices in Laravel applications with middleware, guards, and validation.

Updated Nov 19, 2025
One-click install
npx skills add https://github.com/Sake-Team/SmartSake --skill laravel-security-sake-team
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: laravel-security
Source: https://github.com/Sake-Team/SmartSake/tree/main/backup/skills/laravel-security
Command: npx skills add https://github.com/Sake-Team/SmartSake --skill laravel-security-sake-team

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes scripts (resource) and references (resource) components.

What problem does it solve?

This Skill addresses common security vulnerabilities in Laravel applications, ensuring secure user authentication, input validation, and deployment practices.

Core Features & Use Cases

  • Authentication and Authorization: Secure user access control with middleware, guards, and policies.
  • Input Validation: Prevent security breaches through strict input validation rules.
  • Deployment Hardening: Set up production security measures like session management and secure headers.
  • Use Case: Protect a Laravel application against CSRF attacks, SQL injection, XSS, and other common threats by applying the best security practices outlined in this Skill.

Quick Start

Load the laravel-security skill to enforce security best practices across your Laravel application.

Frequently Asked Questions about laravel-security

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I protect a Laravel application against CSRF and XSS attacks?

Protect a Laravel application against CSRF and XSS attacks by applying security best practices using middleware, form requests, and strict data validation rules to filter malicious input.

What is the best way to implement secure authentication in Laravel?

Secure authentication in Laravel is best implemented by configuring custom guards, defining authorization policies, and applying middleware to enforce strict user access control across application routes.

How do I set up input validation to prevent SQL injection in Laravel?

Prevent SQL injection in Laravel by using form requests to enforce strict input validation rules, ensuring all user-submitted data is sanitized and validated before interacting with the database.

Does this approach support deployment hardening for Laravel production environments?

Yes, this approach supports deployment hardening for Laravel production environments by configuring secure session management, enforcing secure HTTP headers, and applying robust production security measures.

When do I need to configure rate limiting in a Laravel application?

Configure rate limiting in a Laravel application when you need to protect authentication endpoints and public routes from brute force attacks and excessive automated request flooding.