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

Unable to parse IPv6 addresses #509

Closed
ctron opened this issue Jul 6, 2019 · 0 comments · Fixed by #510
Closed

Unable to parse IPv6 addresses #509

ctron opened this issue Jul 6, 2019 · 0 comments · Fixed by #510

Comments

@ctron
Copy link
Contributor

ctron commented Jul 6, 2019

In the 0.3.x version of Milo, it fails to parse IPv6 addresses.

The problem is in the endpoint pattern which is expected. An IPv6 address may look like [fe80::9289:e377:bacb:f608%enp0s31f6], and thus may contain :, % and [].

The result is a complain about an unsupported protocol:

Exception in thread "main" java.util.concurrent.ExecutionException: UaException: status=Bad_InternalError, message=unsupported protocol: null
	at java.base/java.util.concurrent.CompletableFuture.reportGet(CompletableFuture.java:395)
	at java.base/java.util.concurrent.CompletableFuture.get(CompletableFuture.java:1999)
	at de.dentrassi.ece2017.milo.step02.Browse.main(Browse.java:31)
Caused by: UaException: status=Bad_InternalError, message=unsupported protocol: null
	at org.eclipse.milo.opcua.stack.client.DiscoveryClient.getEndpoints(DiscoveryClient.java:189)
	at de.dentrassi.ece2017.milo.step01.Connect.createClient(Connect.java:54)
	at de.dentrassi.ece2017.milo.step01.Connect.connect(Connect.java:67)
	... 1 more
kevinherron added a commit that referenced this issue Jul 6, 2019
This isn't recognizing or validating IPv6 addresses so much as just
allowing the possibility of an IPv6 address in the hostname position by
allowing anything inside a pair of square brackets to be treated as a
hostname.

fixes #509
kevinherron added a commit that referenced this issue Jul 9, 2019
This isn't recognizing or validating IPv6 addresses so much as just
allowing the possibility of an IPv6 address in the hostname position by
allowing anything inside a pair of square brackets to be treated as a
hostname.

fixes #509
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants