# Error: error:0606506D:digital envelope routines

**URL:** <https://community.auth0.com/t/error-errordigital-envelope-routines/117743>\
**Category:** Get Help\
**Tags:** ad-ldap-enterprise-connection, connections\
**Created:** [October 4, 2023, 4:07am UTC](https://community.auth0.com/t/error-errordigital-envelope-routines/117743 "2023-10-04T04:07:34Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![kurt.dunn](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/kurt.dunn/32/72021_2.png) [@kurt.dunn](https://community.auth0.com/u/kurt.dunn)\
**Post date:** [October 4, 2023, 4:07am UTC](https://community.auth0.com/t/error-errordigital-envelope-routines/117743/1 "2023-10-04T04:07:34Z")

</div>

Hi,

I have created a new Auth0 Active Directory/LDAP Connector v6.1.8 on a Ubuntu server. I have added all the credentials.

When i run node server its throwing a Error: error:0606506D:digital envelope routines:EVP\_DecryptFinal\_ex:wrong final block length

Is this a bug in the code?

```auto
node server.js
[2023-10-04 03:48:59] Reading CA certificates from OPENSSLDIR
[2023-10-04 03:48:59] Reading CA certificates from /usr/lib/ssl/certs
[2023-10-04 03:48:59] Adding 125 certificates
[2023-10-04 03:48:59] Loading settings from ticket: https://bfs-dev.au.auth0.com/p/ad/iJR8jiuaNnTF4EZuMpRjYUCPiMwt72Rm/info
[2023-10-04 03:48:59] Is Anonymous LDAP search enabled? no
[2023-10-04 03:48:59] Local settings updated.
[2023-10-04 03:48:59] Certificates already exist, skipping certificate generation.
[2023-10-04 03:48:59] Configuring connection bfs-dev.
[2023-10-04 03:48:59] > Posting certificates and signInEndpoint: http://<myip>:4000/wsfed
[2023-10-04 03:48:59] Connection bfs-dev configured.
[2023-10-04 03:48:59] Connector setup complete.
[2023-10-04 03:48:59] Error: error:0606506D:digital envelope routines:EVP_DecryptFinal_ex:wrong final block length
    at Decipheriv.final (internal/crypto/cipher.js:172:29)
    at Object.exports.decrypt (/opt/auth0-adldap/lib/crypto.js:47:76)
    at initializeConnection (/opt/auth0-adldap/lib/ldap.js:97:71)
    at Object.get [as binder] (/opt/auth0-adldap/lib/ldap.js:129:24)
    at new module.exports (/opt/auth0-adldap/lib/users.js:54:29)
    at Object.<anonymous> (/opt/auth0-adldap/ws_validator.js:8:13)
    at Module._compile (internal/modules/cjs/loader.js:999:30)
    at Object.Module._extensions..js (internal/modules/cjs/loader.js:1027:10)
    at Module.load (internal/modules/cjs/loader.js:863:32)
    at Function.Module._load (internal/modules/cjs/loader.js:708:14)
[2023-10-04 03:51:32] Error: read ECONNRESET

```

---

<div class="post-metadata">

**Author:** ![kurt.dunn](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/kurt.dunn/32/72021_2.png) [@kurt.dunn](https://community.auth0.com/u/kurt.dunn)\
**Post date:** [October 4, 2023, 4:31am UTC](https://community.auth0.com/t/error-errordigital-envelope-routines/117743/2 "2023-10-04T04:31:19Z")

</div>

I figured it out.

OpenSSL needed to be on installed before running npm install. This should be in the install doco…

---

<div class="post-metadata">

**Author:** ![system](https://global.discourse-cdn.com/auth0/original/3X/b/5/b560f266932fcce5d57f09a6595bd50518cae3f3.jpeg) [@system](https://community.auth0.com/u/system)\
**Post date:** [October 18, 2023, 4:31am UTC](https://community.auth0.com/t/error-errordigital-envelope-routines/117743/3 "2023-10-18T04:31:37Z")

</div>

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.
