> For the complete documentation index, see [llms.txt](https://docs.poshtools.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.poshtools.com/open-source-tools/visual-studio-code/sign-on-save.md).

# Sign On Save

Sign scripts after they are saved.

The Sign on Save features provides a way to sign scripts right after they are saved using a configured code-signing certificate.

## Configuring Sign On Save

You can configure sign on save by enabling the feature in settings and providing a certificate path.

![](https://3667946160-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-LNFE66tpE_51uobNA70%2F-MZJgXHw7KwsCZMvOXjs%2F-MZJhS6b7O8rNfJ0jZgS%2Fimage.png?alt=media\&token=20389a09-4f32-40f6-860b-d4310bb31084)

The path can be left empty and the extension will provide a quick pick drop down the first time you save a file.

![](https://3667946160-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-LNFE66tpE_51uobNA70%2F-MZJgXHw7KwsCZMvOXjs%2F-MZJheC8lja-spmsI8P6%2Fimage.png?alt=media\&token=c8eb1ae0-9dc1-470f-a065-3116c4126d56)

Once you select a certificate, it will store that in the Sign On Save Certificate setting. You'll notice the setting is the full path to the certificate in the certificate store.

```
Microsoft.PowerShell.Security\Certificate::CurrentUser\My\Aasdfasdf23fdasfd0as872389723soad
```

With the setting enabled, any time you save a file, `Set-AuthenticodeSignature` will be called and your file will be signed.
