[DOC]: cuda.core 1.1.1 note misstates program cache permissions
Nessuno ha ancora preso questa issue.
Valutazione
- Difficoltà
- 1/5
- Tempo stimato
- Meno di un'ora
- Idoneità per principianti
- 88/100
- Tipo di issue
- Documentazione
- Chiarezza
- Specificata chiaramente
- Stato di attività
- Attiva
- Stack tecnologico
- python
- Ambito
- documentation
Direzione di ricerca
Leggi la nota di rilascio collegata di cuda-core 1.1.1 e confrontala con cuda_core/cuda/core/utils/_program_cache/_file_stream.py. Esegui, se necessario, l’esempio FileStreamProgramCache fornito per verificare i permessi indicati. Il lavoro è completo quando la nota descrive accuratamente la radice della cache, le voci, i file delle voci, la directory tmp, il comportamento di umask e qualsiasi compromesso documentato relativo a una cache condivisa.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Descrizione
- I confirmed there appear to be no duplicate issues for this bug and that I agree to the Code of Conduct
Is this for new documentation, or an update to existing docs?
Update
Describe the incorrect/future/missing documentation
The cuda.core 1.1.1 release note says the on-disk program cache directory is created with owner-only permissions (0o700), that those permissions are re-asserted on each use, and that this prevents other local users from reading or injecting cached device code regardless of the process umask. Only the tmp/ staging directory is created 0o700. The cache root, entries/ and the shard directories inherit the umask, and no permissions are re-asserted, so a cache created under a permissive umask stays world-writable after a write.
import os, stat, tempfile
from pathlib import Path
from cuda.core.utils import FileStreamProgramCache
os.umask(0o000)
root = Path(tempfile.mkdtemp()) / "pc"
FileStreamProgramCache(path=root)["k"] = b"hello"
for p in (root, root / "entries", root / "tmp"):
print(p.name, oct(stat.S_IMODE(os.stat(p).st_mode)))
pc 0o777
entries 0o777
tmp 0o700
Expected: the note describes what shipped. Cache entry files are 0o600 and tmp/ is 0o700, so cached device code is not readable by other users, but the cache root and entries/ follow the umask and a pre-existing shared cache directory is used as-is.
cuda_core/cuda/core/utils/_program_cache/_file_stream.py also records the trade-off this leaves (a deliberately shared writable entries/ lets a co-owner replace a cached file). Whether the note should state that as well is your call.
If this is a correction, please provide a link to the incorrect documentation. If this is a new documentation request, please link to where you have looked.
https://nvidia.github.io/cuda-python/cuda-core/latest/release/1.1.1-notes.html
- Lingua principale
- Cython
- Stelle
- 3.4k
- Fork
- 329
- Merge medio
- 1g 20h
- PR unite (30g)
- 123
Guida per i contributori
Apri la guida per i contributori
Come iniziare
- Leggi tutta la issue e poi la guida ai contributi del progetto.
- Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
- Fai un fork del repository e lavora su un branch.
- Apri una pull request che faccia riferimento al numero della issue.
Altre issue di NVIDIA/cuda-python
-
bug cuda.core
Difficoltà 2/5 1-3 ore Idoneità per principianti 76/100
NVIDIA/cuda-python#2886 · 1 commento ·
-
triage
Difficoltà 1/5 1-3 ore Idoneità per principianti 90/100
NVIDIA/cuda-python#2712 ·
-
triage
Difficoltà 2/5 1-3 ore Idoneità per principianti 82/100
NVIDIA/cuda-python#2646 · 1 reazione ·
-
cuda.core triage
Difficoltà 2/5 1-3 ore Idoneità per principianti 62/100
NVIDIA/cuda-python#2435 · 1 commento ·
-
bug cuda.core P2
NVIDIA/cuda-python#2918 · 1 assegnatario ·
Tutte le issue di NVIDIA/cuda-python
Issue simili
-
Difficoltà 1/5 Meno di un'ora Idoneità per principianti 95/100
Git-it-App/git-it-electron#1047 ·
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 75/100
neondatabase/website#5944 ·
-
📕documentation
Difficoltà 2/5 1-3 ore Idoneità per principianti 75/100
db-ux-design-system/core-web#8239 ·
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 70/100
libsdl-org/sdlwiki#1008 ·
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 70/100