Configurable user-profile loading: WINRS_NOPROFILE is hardcoded (winrs -noprofile)
Nessuno ha ancora preso questa issue.
Valutazione
- Difficoltà
- 4/5
- Tempo stimato
- 3-5 giorni
- Idoneità per principianti
- 68/100
- Tipo di issue
- Funzionalità
- Chiarezza
- Abbastanza chiara
- Stato di attività
- Tranquilla
- Stack tecnologico
- java
- Ambito
- backend-api-design, cli, documentation, testing
Direzione di ricerca
Inizia da Envelopes.createShell e segui il flusso esistente di blocco della directory di lavoro e ricreazione della shell. Poi esamina il parsing della CLI per i comandi e la shell, oltre a commands.md e cli.md, e aggiungi o aggiorna i test per l’opzione Create, la riproduzione con directory bloccata e il comportamento della CLI. Il lavoro è completato quando il caricamento dei profili rimane disabilitato per impostazione predefinita, può essere richiesto per ogni shell, viene riprodotto dopo la ricreazione e il relativo errore per i non amministratori è documentato.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Descrizione
winrs parity:
-nop[rofile]— except our polarity is reversed: winrs loads the profile by default and-noprofileturns it off; this client hardcodesWINRS_NOPROFILE=TRUEin the shell Create options, so the profile is never loaded and there is no way to ask for it.
Context
Envelopes.createShell always sends:
<wsman:Option Name="WINRS_NOPROFILE">TRUE</wsman:Option>
That is the safe default — winrs's load-the-profile default fails for users who are not local administrators on the target — but some commands genuinely need the user profile (HKCU hive, %APPDATA%, per-user PATH), and today they cannot have it.
Proposed API
CommandResult result = client.command("reg query HKCU\Software\...")
.loadUserProfile() // shell-scoped, like workingDirectory: first command pins it
.execute();
Keep NOT loading the profile as the default — it is both the current behavior and the choice that works for non-admin users.
CLI
--profile on command (and shell, #136):
winrm-java -h server -u 'DOMAIN\user' -pf pw.txt --profile exec 'echo %APPDATA%'
Requirements
- Shell-scoped setting with the same pinning semantics as the working directory (replayed with its original value when a reaped shell is silently recreated).
- Document the failure mode: requesting the profile as a non-admin typically faults — the fault surfaces through the normal
WinRMFaultExceptionpath with its code and detail. - Tests: wire assertion of the option value on Create, pinned replay on recreation, CLI parsing; docs (commands.md + cli.md).
🤖 Generated with Claude Code
- Lingua principale
- Java
- Stelle
- 11
- Fork
- 4
- Merge medio
- 5g 5h
- PR unite (30g)
- 6
Guida per i contributori
Nessuna guida per i contributori indicizzata per questo repository
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 MetricsHub/winrm-java
-
Difficoltà 5/5 Più di una settimana Idoneità per principianti 35/100
MetricsHub/winrm-java#148 ·
-
Difficoltà 5/5 Più di una settimana Idoneità per principianti 35/100
MetricsHub/winrm-java#147 ·
-
Difficoltà 5/5 Più di una settimana Idoneità per principianti 38/100
MetricsHub/winrm-java#146 ·
-
Difficoltà 5/5 Più di una settimana Idoneità per principianti 35/100
MetricsHub/winrm-java#145 ·
-
Kerberos credential delegation: allowDelegation() and CLI --allow-delegate (winrs -allowdelegate) Aperta
Difficoltà 4/5 3-5 giorni Idoneità per principianti 48/100
MetricsHub/winrm-java#141 ·
Tutte le issue di MetricsHub/winrm-java
Issue simili
-
Bug Java Platform: Java
Difficoltà 2/5 1-3 ore Idoneità per principianti 78/100
getsentry/sentry-java#6138 · 1 commento ·
-
bug needs triage p2
Difficoltà 2/5 1-3 ore Idoneità per principianti 78/100
GoogleCloudPlatform/DataflowTemplates#4273 · 1 commento ·
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 78/100
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 76/100
-
bug needs triage
Difficoltà 2/5 1-3 ore Idoneità per principianti 76/100