Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add support for ALPN TLS extension #1332

Merged
merged 2 commits into from Dec 21, 2021
Merged

Add support for ALPN TLS extension #1332

merged 2 commits into from Dec 21, 2021

Conversation

marcotuna
Copy link
Contributor

This Pull Request adds support for ALPN.
With this change it is now possible to use AWS MQTT Broker on Port 443 with Custom Authorization.
More information at: https://docs.aws.amazon.com/iot/latest/developerguide/protocols.html

This change is not AWS specific, there's more use cases behind the support of this feature.

For more references have a look at the NodeJS types repository: https://github.com/DefinitelyTyped/DefinitelyTyped/blob/master/types/node/tls.d.ts#L446

Example:

mqtt.connect("AWS_ACCOUNT_ID-ats.iot.eu-west-1.amazonaws.com", {
  ...
  port: 443,
  ALPNProtocols = ['mqtt']
  ...
})

@marcotuna
Copy link
Contributor Author

Hey @YoDaMa. Can you have a look on this?
Do you need more clarifications about it?
The current use case that this is attempting to solve is to support AWS iot without any specific AWS code. The current implementation is generic and might allow different integrations with MQTT Brokers using Reverse Proxies using TLS APLN capabilities.

@YoDaMa YoDaMa merged commit 06f2fd2 into mqttjs:master Dec 21, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants