oasis-core
oasis-core copied to clipboard
throw error, if '~' is used in oasis-node config file for paths
SUMMARY
Using ~ in the config file for oasis-node does not work, for example:
datadir: ~/node/data
In this case badger will create a new directory called ~ in cwd instead of interpreting the symbol as home and then oasis-node will crash saying it cannot access ~/node/data directory. One can image what a rm -r ~ would then result without escaping the ~ symbol in :wink:
EXPECTED RESULTS
I suggest we throw error when parsing the config file, if any of the paths contain ~ symbol. Are there any other special characters in posix paths we should avoid?