Fixing Issue #6301 on master branch

Added private var $certPath to store the user root cert

Move logic to determine the $certPath path to the constructor and modify to get the path from OC_User::getHome()

Add curl options to use the certificate to avoid certificate errors with self-signed certicates in the downdload/upload method so we don't get blank files

Only set SSL things when ```$this->secure``` is ```true```

Fix ```createCertificateBundle``` and  ```getCertificates``` methods
from ```OC_Mount_config``` to use ```OC_User::getHome``` to get the
path

Backport of 7c264c88fe06c61ef602fa8a241428c99f220061,
b245e2e3d86299092448e3223b0d658d88206873 and
c06844c374c145b2f05ae0800678f68acc9ae2e3 to stable6 (squashed)