Changing generic onion to one generated earlier
- Check the current .onion generated when you first setup TOR (in case you want to use it)
> cd /var/lib/tor/hidden_service/
> cat hostname
- If you wish to use a custom address, delete (or move) the old keys
> cd /var/lib/tor/hidden_service/
> rm -rf *
- locate the keys to copy
> cd /home/<your username>/Downloads/mkp224o/<key folder name>/<key folder>/
example
> cd /home/user/Downloads/mkp224o/websitekeys/websitehz44l75xucojrrqofi4v7rn4y75wu6ocn7zbwjazgr44prfyd.onion/
> ls -al
- Copy the generated keys to the onion service location
> sudo cp * /var/lib/tor/hidden_service/
- change ownership of the copied keys so the service can access them
> sudo chown debian-tor:debian-tor /var/lib/tor/hidden_service/*
- restart the tor service
> sudo service tor restart