Jonathan
Jonathan
When I use one of the suggested fix, I got the following exception : `'DER was not encoded.'` thrown by `ASN1::encodeDER`
Removing **extensions** from certificate options seems to resolve the DER error.
In `ASN1::encodeDERInternale`, the condition `!isset($source[$key])` is true and then continue, so the variable `$temp` remains **false**. At the end of the block, it will return **false**, causing the DER exception.
Problem is the key is 'dNSName' (according to the documentation). This doesn't exist in phpseclib.
In case of code and passed string is already in unicode, utf8_encode will break the request. I will try to add an encoding detection before utf8_encode.
I guess this litlle snippet can do the job. `//ensure content is unicode encoding` `if (!mb_check_encoding($content, 'UTF-8')) {` ` $content = utf8_encode($content);` `}` (will be included in my incoming pull...
Bump ;-)