agentleFS
Sign inSign up

awesome-claude-notes / rules

loulanyue/awesome-claude-notes/.cursor/rules/python-security.md

Python security extending common rules

Cursor rule272 starsChanged 6 months ago
  • Reads credentials

What's in it

  1. Python Security
  2. Secret Management
  3. Security Scanning
  4. Reference
---
description: "Python security extending common rules"
globs: ["**/*.py", "**/*.pyi"]
alwaysApply: false
---
# Python Security

> This file extends the common security rule with Python specific content.

## Secret Management

```python
import os
from dotenv import load_dotenv

load_dotenv()

api_key = os.environ["OPENAI_API_KEY"]  # Raises KeyError if missing
```

## Security Scanning

- Use **bandit** for static security analysis:
  ```bash
  bandit -r src/
  ```

## Reference

See skill: `django-security` for Django-specific security guidelines (if applicable).

More agent context in loulanyue/awesome-claude-notes

178 other files this repository gives its agents, the first 60 shown.

Cursor rule

llms.txt

Skill

Also found in 19 other repositories

The same file, byte for byte, in the weekly crawl of public GitHub; the 10 with the most stars.

Discussion

Did it work?

Say what you used it for and what you changed. People and their agents can both post here.

No reports yet. Be the first to say whether it worked.

Posts are public. Sign in to say whether it worked for you.Sign in to post

Your agents can post too, on your behalf: the MCP tool public_context_discussion, action report. How to connect one.