Comments (4)
This is kind of a chicken and egg thing. SecretStore needs a configuration when loaded and it will default to the interactive password required configuration by default.
You can avoid this by running Set-SecretStoreConfiguration
first thing after installing the module (before you register SecretStore as an extension vault).
Alternatively, you can also use the Reset-SecretStore
to force set the configuration. This causes any secret data to be deleted, but since you haven't yet added any secret data, it should be Ok to use.
PS C:\> Register-SecretVault -ModuleName Microsoft.PowerShell.SecretStore -Name SecretStore -DefaultVault
PS C:\> Reset-SecretStore -Authentication None -Interaction None -Force
WARNING: !!This operation completely removes all SecretStore module secrets and resets configuration settings to new values!!
PS C:\> Set-Secret -Name Testing -Secret 'Testing123'
PS C:\> Get-SecretInfo
Name Type VaultName
---- ---- ---------
Testing String SecretStore
PS C:\> Get-Secret -Name Testing -AsPlainText
Testing123
from secretstore.
@PaulHigin, thanks! that appears to work for me.
I would think that when the vault is initially configured it would splat the parameters from -VaultParameters
and use those as the new defaults. It seems odd that in your example, the "Authentication" and "Interaction" parameters are specified twice.
from secretstore.
Whoops, I just copied/pasted. There is no need to pass Authentication/Interaction as vault parameters, as SecretStore does not currently handle them.
from secretstore.
@PaulHigin Ah! Okay, that completely clears that up then. Thanks! I guess since this isn't a bug, and it's intentional (though I'd admit a bit of an odd workflow) I'll close with comment. Thanks!
from secretstore.
Related Issues (20)
- Upgrading PowerShell Core version affected secrets store HOT 6
- Getting "Padding is invalid and cannot be removed" when trying to use store in local session when it was set up with remoting HOT 38
- Add better error message for failure when running under Windows built-in accounts HOT 1
- SecretStore requires Full Language mode HOT 5
- need documentation on backup/restore operation of the vaults HOT 2
- Passswordless SecretManagement
- How to use SecretStore for automatic pwd PSSession to linux? HOT 2
- Registering an additional store just creates another reference to the first store HOT 5
- There is no possibility to choose a custom file path HOT 6
- Set-SecretStoreConfiguration -Authentication None often fails HOT 7
- Request - Lock-SecretStore cmdlet HOT 1
- Windows 11 Upgrade: Store File Corruption HOT 2
- Set-SecretStoreConfiguration doesn't properly support Confirm:$false HOT 4
- Unlock-SecretStore not working when using Remote-SSH connection in VsCode HOT 4
- Cannot use Set-SecretStorePassword with parameter arguments to set a new password, without an existing password HOT 1
- Updating module in pwsh 7.2
- Reset-SecretStore doesn't respect-Confirm:$false
- Set-SecretStoreConfiguration failed under Linux HOT 1
- Unlock-SecretStore randomly fails after running Reset-SecretStore
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from secretstore.