Bustacap: - close GOG Galaxy if it's running at the moment  
 - log in to the Playstation Store (store.playstation.com) through your browser 
 (if you were already logged in, log out first, then back in)  
 - after the login open this link: 
https://ca.account.sony.com/api/v1/ssocookie   youll get something like: {"npsso":"xxx"} 
 where xxx is the npsso value  
 (example of what it should look like: 
https://abload.de/img/npssomcj9f.png )  
 - open windows explorer and enter the following into the address bar at the top and press enter 
 %LocalAppData%\GOG.com\Galaxy\plugins\installed\  
 ( 
https://abload.de/img/localappdataojjbg.png )  
 - open the psn_{random number} folder and edit the plugin.py file with your favourite text editor  
 - go to line 64. it sould look like this: 
 stored_npsso = stored_credentials.get("npsso") if stored_credentials else None  
 delete everything on that line after: stored_npsso = 
 then add your npsso value behind it in quotation marks.  
 it should look like this: 
 stored_npsso = "npsso value"  
 ("npsso value" is the value from step 3 and should be a 64 character long text consisting of numbers, lower case letters and upper case letters) 
 (the quotation marks " " are important!)  
 (example of what it should look like: 
https://abload.de/img/plugingrjah.png )  
 - save the changes made to plugin.py and close the file 
 - restart GOG Galaxy 
 - try connecting with PSN again