Skip to content

security: add X-DNS-Prefetch-Control header#2236

Open
Honey-pg wants to merge 5 commits into
Priyanshu-byte-coder:mainfrom
Honey-pg:security/x-dns-prefetch-control-on
Open

security: add X-DNS-Prefetch-Control header#2236
Honey-pg wants to merge 5 commits into
Priyanshu-byte-coder:mainfrom
Honey-pg:security/x-dns-prefetch-control-on

Conversation

@Honey-pg

@Honey-pg Honey-pg commented Jun 9, 2026

Copy link
Copy Markdown
Contributor

Summary

Set X-DNS-Prefetch-Control: on in next.config.mjs so the application explicitly controls DNS prefetching behavior.

Closed #2016


Type of Change

  • Bug fix
  • New feature
  • Documentation update
  • Refactor / code cleanup

Changes Made

  • Added X-DNS-Prefetch-Control: on to the global security headers in next.config.mjs

How to Test

  1. Run npm run build (or npm run dev) and start the app
  2. Open any page and inspect response headers (browser DevTools → Network → document request)
  3. Confirm X-DNS-Prefetch-Control: on is present on responses

Checklist

  • Linked issue in summary
  • npm run lint passes locally
  • No TypeScript errors (npm run type-check)
  • Self-reviewed the diff
  • Added/updated tests if applicable

Additional Notes

This is a security header addition only; no UI or API behavior changes. Note: an existing branch security/x-dns-prefetch-control uses off instead of on — confirm which value is intended before merging.

Set X-DNS-Prefetch-Control to on so the application explicitly controls DNS prefetching behavior.
@vercel

vercel Bot commented Jun 9, 2026

Copy link
Copy Markdown

@Honey-pg is attempting to deploy a commit to the PRIYANSHU DOSHI's projects Team on Vercel.

A member of the Team first needs to authorize it.

@github-actions github-actions Bot added gssoc26 GSSoC 2026 contribution type:feature GSSoC type bonus: new feature type:security GSSoC type bonus: security (+20 pts) labels Jun 9, 2026
@github-actions

github-actions Bot commented Jun 9, 2026

Copy link
Copy Markdown

GSSoC Label Checklist 🏷️

@Priyanshu-byte-coder — please apply the appropriate labels before merging:

Difficulty (pick one):

  • level:beginner — 20 pts
  • level:intermediate — 35 pts
  • level:advanced — 55 pts
  • level:critical — 80 pts

Quality (optional):

  • quality:clean — ×1.2 multiplier
  • quality:exceptional — ×1.5 multiplier

Validation (required to score):

  • gssoc:approved — counts for points
  • gssoc:invalid / gssoc:spam / gssoc:ai-slop — does not score

Type labels (type:*) are auto-detected from files and title. Review and adjust if needed.
Points formula: (difficulty × quality_multiplier) + type_bonus

Honey-pg and others added 2 commits June 9, 2026 11:25
Replace page.evaluate fetch on about:blank with Playwright request + session cookie so relative API URLs resolve. Assert authenticated access returns JSON instead of requiring GitHub 200 with mock token.
@github-actions github-actions Bot added the type:testing GSSoC type bonus: tests (+10 pts) label Jun 9, 2026
Honey-pg added 2 commits June 9, 2026 13:37
Stub github-orgs, daily-focus, and dashboard-layout in dashboard E2E specs so placeholder Supabase env does not trigger resolveAppUser server errors during Playwright runs.
Add shared dashboard API mocks with correct streak/freeze payloads, relax middleware rate limits under PLAYWRIGHT_TEST, set PLAYWRIGHT_TEST in CI, use stable locators and scroll helpers, and run E2E with a single worker to avoid server contention.
@github-actions github-actions Bot added the type:devops GSSoC type bonus: devops (+15 pts) label Jun 9, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

gssoc26 GSSoC 2026 contribution type:devops GSSoC type bonus: devops (+15 pts) type:feature GSSoC type bonus: new feature type:security GSSoC type bonus: security (+20 pts) type:testing GSSoC type bonus: tests (+10 pts)

Projects

None yet

Development

Successfully merging this pull request may close these issues.

sec: Add X-DNS-Prefetch-Control Header

1 participant