[ Posting back to the ubuntu-devel mailing list ]

On 12/29/2016 07:42 PM, Thomas Ward wrote:
You could use /etc/hosts to define a dummy host name that Firefox could 
recognize.


I have added this line to /etc/hosts and it did not work:

fe80::e828:7eff:fe19:9962%ippusbxd      ippusbxd-printers

I have also tried

fe80::e828:7eff:fe19:9962%25ippusbxd    ippusbxd-printers

and also put "[...]" around the IP address. When I try to resolve the name ippusbxd-printers (for example with "wget") I get something like

Dec 29 20:18:38 till-x1carbon systemd-resolved[1462]: Address 'fe80::e828:7eff:fe19:9962%ippusbxd' is invalid, in line /etc/hosts:10.

in /var/log/syslog.

If I add the line

fe80::e828:7eff:fe19:9962       ippusbxd-printers

wget can resolve the IP address from the name, but it cannot access as the interface is not specified:

till@till-x1carbon:~$ wget ippusbxd-printers:60000
--2016-12-29 20:24:11--  http://ippusbxd-printers:60000/
Resolving ippusbxd-printers (ippusbxd-printers)... fe80::e828:7eff:fe19:9962
Connecting to ippusbxd-printers (ippusbxd-printers)|fe80::e828:7eff:fe19:9962|:60000... failed: Invalid argument.
till@till-x1carbon:~$

Specifying the interface is not accepted by wget, wget considers the interface as a part of the name:

till@till-x1carbon:~$ wget ippusbxd-printers%ippusbxd:60000
--2016-12-29 20:45:52--  http://ippusbxd-printers%25ippusbxd:60000/
Resolving ippusbxd-printers%ippusbxd (ippusbxd-printers%ippusbxd)... failed: Name or service not known.
wget: unable to resolve host address ‘ippusbxd-printers%ippusbxd’
till@till-x1carbon:~$ wget ippusbxd-printers%25ippusbxd:60000
--2016-12-29 20:45:59--  http://ippusbxd-printers%25ippusbxd:60000/
Resolving ippusbxd-printers%ippusbxd (ippusbxd-printers%ippusbxd)... failed: Name or service not known.
wget: unable to resolve host address ‘ippusbxd-printers%ippusbxd’
till@till-x1carbon:~$

In Firefox it is even worse. The name, either with and without specification of the interface is not resolved at all and Firefox tries to add "www." and ".com".

   Till






*Sent from my iPhone.  Please excuse any typos, as they are likely to happen by 
accident.*

On Dec 29, 2016, at 16:33, Till Kamppeter <till.kamppe...@gmail.com> wrote:

On 12/29/2016 05:27 PM, Philipp Kern wrote:
On 12/29/2016 08:16 PM, Till Kamppeter wrote:
This would especially mean that I can access the printer's web admin
interface by pointing a browser to this address so I try the simple
command line browser wget:

curl seems to work:

$ curl "http://[fe80::3664:a9ff:fe9a:f5b8%25br0]/";
No such site at :80
$ curl "http://[fe80::3664:a9ff:fe9a:f5b8%br0]/";
No such site at :80

If only we had universal support for interface scopes by having a
unified function that parses IP addresses...

Kind regards
Philipp Kern


Thank you very much.

curl 'http://[fe80::e828:7eff:fe19:9962%25ippusbxd]:60000/' > testfile.gz
gunzip testfile.gz

gives an actual HTML file.

I am not able to open this URL with Firefox, as this browser does not seem to 
understand the syntax of the IPv6 URL.

Is there a way to make a local Zeroconf host name get assigned to this IPv6 IP 
address?

  Till


--
ubuntu-devel mailing list
ubuntu-devel@lists.ubuntu.com
Modify settings or unsubscribe at: 
https://lists.ubuntu.com/mailman/listinfo/ubuntu-devel


--
ubuntu-devel mailing list
ubuntu-devel@lists.ubuntu.com
Modify settings or unsubscribe at: 
https://lists.ubuntu.com/mailman/listinfo/ubuntu-devel

Reply via email to