Added ability to store password in .netrc file
and fixed if.
Closing DEV-17 #resolved #fixed