Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions .github/workflows/security.yml
Original file line number Diff line number Diff line change
Expand Up @@ -93,6 +93,7 @@ jobs:
push: false
load: true
tags: blog-backend:scan
no-cache: true

- name: Build frontend image for scanning
uses: docker/build-push-action@v5
Expand All @@ -102,6 +103,7 @@ jobs:
push: false
load: true
tags: blog-frontend:scan
no-cache: true

# Scan application libraries - BLOCKS pipeline on vulnerabilities
- name: Run Trivy scanner on backend - Application Libraries
Expand Down
2 changes: 1 addition & 1 deletion TODO.md
Original file line number Diff line number Diff line change
Expand Up @@ -158,7 +158,7 @@
JWT_ACCESS_TOKEN_EXPIRES=14400

RESEND_API_KEY=<YOUR_RESEND_API_KEY>
MAIL_DEFAULT_SENDER=noreply@computeranything.dev
MAIL_DEFAULT_SENDER=noreply@notifications.computeranything.dev
CONTACT_FORM_RECIPIENTS=contact@computeranything.dev

ADMIN_EMAIL=admin@computeranything.dev
Expand Down
2 changes: 1 addition & 1 deletion backend/config.py
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ class Config:

# Email Configuration (Resend API)
RESEND_API_KEY = os.environ.get('RESEND_API_KEY')
MAIL_DEFAULT_SENDER = os.environ.get('MAIL_DEFAULT_SENDER', 'noreply@computeranything.dev')
MAIL_DEFAULT_SENDER = os.environ.get('MAIL_DEFAULT_SENDER', 'noreply@notifications.computeranything.dev')

# Admin Email (for security alerts)
ADMIN_EMAIL = os.environ.get('ADMIN_EMAIL')
Expand Down
3 changes: 3 additions & 0 deletions backend/requirements.txt
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
# Security overrides - MUST be first to take precedence
jaraco.context==6.1.0

# Core Flask
Flask==2.3.3
Flask-SQLAlchemy==3.0.5
Expand Down
6 changes: 3 additions & 3 deletions backend/utils/email.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ def send_email(to: str | list[str], subject: str, html: str, from_email: str | N
to: Email address or list of email addresses
subject: Email subject
html: HTML content of the email
from_email: Sender email (defaults to noreply@computeranything.dev)
from_email: Sender email (defaults to noreply@notifications.computeranything.dev)
reply_to: Reply-to email address (optional)

Returns:
Expand Down Expand Up @@ -48,7 +48,7 @@ def send_email(to: str | list[str], subject: str, html: str, from_email: str | N
f"[DEVELOPMENT MODE] Email NOT sent - logged instead:\n"
f" To: {to}\n"
f" Subject: {subject}\n"
f" From: {from_email or 'noreply@computeranything.dev'}\n"
f" From: {from_email or 'noreply@notifications.computeranything.dev'}\n"
f" Reply-To: {reply_to or 'N/A'}\n"
)

Expand Down Expand Up @@ -80,7 +80,7 @@ def send_email(to: str | list[str], subject: str, html: str, from_email: str | N

# Get from email
if from_email is None:
from_email = 'noreply@computeranything.dev'
from_email = 'noreply@notifications.computeranything.dev'

# Ensure to is a list
if isinstance(to, str):
Expand Down
2 changes: 1 addition & 1 deletion docs/security/SECURITY.md
Original file line number Diff line number Diff line change
Expand Up @@ -777,7 +777,7 @@ FRONTEND_URL=https://blog.computeranything.dev
# backend/utils/email.py:85-118
def send_email(to: str, subject: str, html: str):
params = {
"from": "Computer Anything Blog <noreply@computeranything.dev>",
"from": "Computer Anything Blog <noreply@notifications.computeranything.dev>",
"to": [to],
"subject": subject,
"html": html,
Expand Down
Loading