Skip to content

Commit 40b8e58

Browse files
committed
fix: Change AniSkip sidecar file permissions to 0600 for enhanced security
1 parent 309f658 commit 40b8e58

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

internal/api/allanime_smart.go

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -184,7 +184,8 @@ func writeAniSkipSidecar(videoPath string, ep *models.Episode) error {
184184

185185
b, _ := json.MarshalIndent(payload, "", " ")
186186
sidecar := strings.TrimSuffix(videoPath, filepath.Ext(videoPath)) + ".skips.json"
187-
return os.WriteFile(sidecar, b, 0644)
187+
// Restrictive permissions: owner read/write only
188+
return os.WriteFile(sidecar, b, 0600)
188189
}
189190

190191
// WriteAniSkipSidecar is an exported wrapper to write AniSkip sidecar files.

0 commit comments

Comments
 (0)