Skip to main content

better-auth-integration

Integrates Better Auth for JWT-based authentication in Next.js and FastAPI, managing user sessions and protected routes.

Install this skill

or
9/100

Security score

The better-auth-integration skill was audited on Feb 25, 2026 and we found 23 security issues across 3 threat categories, including 2 high-severity. Review the findings below before installing.

Categories Tested

Security Issues

high line 816

Direct command execution function call

SourceSKILL.md
816existing_user = session.exec(
high line 859

Direct command execution function call

SourceSKILL.md
859user = session.exec(
medium line 941

Template literal with variable interpolation in command context

SourceSKILL.md
941Authorization: `Bearer ${session.token}`,
medium line 956

Template literal with variable interpolation in command context

SourceSKILL.md
956const response = await fetch(`${this.baseUrl}${endpoint}`, {
medium line 963

Template literal with variable interpolation in command context

SourceSKILL.md
963throw new Error(error.detail || `HTTP ${response.status}`);
medium line 971

Template literal with variable interpolation in command context

SourceSKILL.md
971return this.request<Task[]>(`/api/${userId}/tasks`);
medium line 975

Template literal with variable interpolation in command context

SourceSKILL.md
975return this.request<Task>(`/api/${userId}/tasks`, {
medium line 982

Template literal with variable interpolation in command context

SourceSKILL.md
982return this.request<Task>(`/api/${userId}/tasks/${taskId}`, {
medium line 989

Template literal with variable interpolation in command context

SourceSKILL.md
989return this.request<Task>(`/api/${userId}/tasks/${taskId}/complete`, {
medium line 995

Template literal with variable interpolation in command context

SourceSKILL.md
995return this.request<void>(`/api/${userId}/tasks/${taskId}`, {
medium line 49

Access to .env file

SourceSKILL.md
49Create `frontend/.env.local`:
low line 69

Access to .env file

SourceSKILL.md
69baseURL: process.env.NEXT_PUBLIC_API_URL || "http://localhost:8000",
medium line 484

Access to .env file

SourceSKILL.md
484Add to `backend/.env`:
low line 524

Access to .env file

SourceSKILL.md
524env_file = ".env"
low line 924

Access to .env file

SourceSKILL.md
924const API_BASE_URL = process.env.NEXT_PUBLIC_API_URL || "http://localhost:8000";
low line 54

External URL reference

SourceSKILL.md
54NEXT_PUBLIC_API_URL=http://localhost:8000
low line 57

External URL reference

SourceSKILL.md
57NEXTAUTH_URL=http://localhost:3000
low line 69

External URL reference

SourceSKILL.md
69baseURL: process.env.NEXT_PUBLIC_API_URL || "http://localhost:8000",
low line 493

External URL reference

SourceSKILL.md
493CORS_ORIGINS=http://localhost:3000
low line 517

External URL reference

SourceSKILL.md
517cors_origins: str = "http://localhost:3000"
low line 924

External URL reference

SourceSKILL.md
924const API_BASE_URL = process.env.NEXT_PUBLIC_API_URL || "http://localhost:8000";
low line 1094

External URL reference

SourceSKILL.md
1094- [Better Auth Documentation](https://better-auth.com/)
low line 1095

External URL reference

SourceSKILL.md
1095- [FastAPI Security](https://fastapi.tiangolo.com/tutorial/security/)
Scanned on Feb 25, 2026
View Security Dashboard