Presented below is an array of characters:
Resource {0: "-", 1: "-", 2: "-", 3: "-", 4: "-", 5: "B", 6: "E", 7: "G", 8: "I", 9: "N", 10: " ", 11: "C", 12: "E", 13: "R", 14: "T", 15: "I", .... }
I am looking to convert it into the following format:
-----BEGIN CERTIFICATE-----
MIIDDTCCAfWgAwIBAgIRAIOTT79H7EtIvqOFiuaLtgAwDQYJKoZIhvcNAQELBQAw
QjEfMB0GA1UECgwWdGVzdC1qcGhhbS51bml0eWRldi5pbzEfMB0GA1UEAwwWdGVz
dC1qcGhhbS51bml0eWRldi5pbzAeFw0xODAyMDcyMTQxNTBaFw0yODAyMDYyMTQx
NTBaMEIxHzAdBgNVBAoMFnRlc3QtanBoYW0udW5pdHlkZXYuaW8xHzAdBgNVBAMM
FnRlc3QtanBoYW0udW5pdHlkZXYuaW8wggEiMA0GCSqGSIb3DQEBAQUAA4IBDwAw
ggEKAoIBAQDJX/QhNgAE2ehS/KhE+j81gwRKbgLbyPy9mhQbYI4e0ZCIufINksjK
AvQVi8/lQ4GAUSHND1/R8K0/oQCA9Z0+hc3Sp+gi7HmuDt63Pt899VH0BiIj7Dr1
wxC2h1ZshwqfMrT22R3nQFNjJ3AkSZFGuUsQqK4UIraRUvdkJFU61Vh/RN8zuTfX
it0uPS0KvXJlJA/XUfKq5P8UsPMdzDCoALU+QF3GrsB0GEwqAjhAjIqDdNyyZyUl
dUG3YrSc70Gmzyt9v7gygahBz6TrTF6qTiLm1x9J6SNLhbZde1RcRJ4FkLD4vHZO
0xGJ6wAIiL6gsOfLxDkDs9pLmmUBsdUJAgMBAAEwDQYJKoZIhvcNAQELBQADggEB
AL23ZqPWrhssRdvz1WrWDN0QrE5yufoFgWJq44te6PLFr1zsyZ/ICDgvu9ykWQUe
ltVQRnhM22GPGmLv6KXYySLQGFyOz51idDuExq1FuF1rLwiZk2VZvy36N0Y0lcIR
VjYTDR7klOGpIeEtnnKrHo2MSMWko/z099WOU9d0Lh8h1QT6WFuS22Kj+UZN9fo5
yWNH/c8ME1f8NByodDNt+xdEZCv7lmGODi+osiQsyTm9J9+YH7aWJqP4q+5s4TFa
mEobuu9zAbqWuehYD5qxfDPLxlRtOeByYHFU+O6/8K0Rsmb0yeSi47q6nS/Sv25/
ftrxe2bjOuaVPHEyYpgnxA4=
-----END CERTIFICATE-----
This is a certificate. Is there a JavaScript solution available for this conversion? Thanks -k