X509 proxy delegation in JavaScript