How to unmark extra-substituters/extra-trusted-public-keys as trusted?

I tried a flake that configured a cache and was prompted to trust it, I accepted:

do you want to allow configuration setting ‘extra-substituters’ to be set to ‘https://cache.something.com’ (y/N)? y
do you want to permanently mark this value as trusted (y/N)? y
do you want to allow configuration setting ‘extra-trusted-public-keys’ to be set to ‘cache…something.com-blablabla’ (y/N)? y
do you want to permanently mark this value as trusted (y/N)? y

How do I undo this? Something was stored somewhere because it’s not asking me again anymore but I can’t find where.

I’m on NixOS, flakes are enabled globally, I didn’t run anything as root.

You can remove it from $XDG_DATA_HOME/nix/trusted-settings.json

2 Likes

I thought I searched in my home but I guess I failed.

No such thing as $XDG_DATA_HOME for me but searching for trusted-settings.json let me to: ~/.local/share/nix/trusted-settings.json

Thank you!