fixing symlink attack bug present in the application.

fixes bug 1233305

Change-Id: I14a94b3b5cb27e8d6c5848c212b3b88053aa8aca
(cherry picked from commit 0805d0a00848fbbb6c719ab484792796c930a33b)