Deny File Access

How would I go about blocking access to a file type, say something like a json file, in EEv4? I know you can’t just modify the existing config file because it keeps getting overwritten.