Fixing restore.sh

* Fixed return values logic
* Changed if statements to modern bash style
* Added quotes on all variables
* Using tab for indentation
* Using mktemp to create a tpm directory instead of
 hardcoded name

Change-Id: I5df0eaf0c18d5d009b1e11c86b35beafecb1b6f0
Signed-off-by: Kiril Nesenko <knesenko@redhat.com>