If you plan on using special characters such as / or $, you will need to use single quotes or else upon saving the file, it will escape the values. Example:
PORTAL_SMTP_USERNAME='Test
\\\\Test'PORTAL_SMTP_PASSWORD='Test$$ca'
Please note the use of single quotes above. If not, the special characters will be chopped.