1

My problem is that I cannot connect to simple HTTP web pages, only to HTTPS secured pages.

Any idea why this would be?

I don't have any proxies. I tested the connection with Windows 7 and it works fine. It's a problem I have with Ubuntu 12.04, with Firefox, Chrome, Midori.

I check the ufw status: it is off.

I performed the test with the curl command, and this is what came out without sudo:

alumno@Usuario:/usr/bin$ curl -I http://www.facebook.com
curl: (7) Failed to connect to 2a03:2880:2110:3f07:face:b00c:0:1: La red es inaccesible
alumno@Usuario:/usr/bin$ curl -I https://www.facebook.com
HTTP/1.1 302 Found
Location: http://www.facebook.com/unsupportedbrowser
P3P: CP="Facebook does not have a P3P policy. Learn why here: http://fb.me/p3p"
X-Content-Type-Options: nosniff
Set-Cookie: datr=FiraUZvP3gAvo3pe5lXNEPDQ; expires=Wed, 08-Jul-2015 02:55:18 GMT; path=/; domain=.facebook.com; httponly
Content-Type: text/html; charset=utf-8
X-FB-Debug: lUBLWH6lEqCWU4GKQS+YeN4/h0eyokinlDsP+aVye1o=
Date: Mon, 08 Jul 2013 02:55:18 GMT
Connection: keep-alive
Content-Length: 0

Then, logging as root, I realized that I could access both HTTP and HTTPS ...therefore, I think it must be a setting as root that does not allow me as user to navigate plain HTTP.

alumno@Usuario:/usr/bin$ sudo curl -I http://www.facebook.com
HTTP/1.1 302 Found
Location: http://www.facebook.com/unsupportedbrowser
Content-Type: text/html; charset=utf-8
X-FB-Debug: ScceJRZGdIwqrHt7QFAU2KTw22yKGunWaosuzH4paik=
Date: Mon, 08 Jul 2013 02:56:19 GMT
Connection: keep-alive
Content-Length: 0

alumno@Usuario:/usr/bin$ sudo curl -I https://www.facebook.com
HTTP/1.1 302 Found
Location: http://www.facebook.com/unsupportedbrowser
P3P: CP="Facebook does not have a P3P policy. Learn why here: http://fb.me/p3p"
X-Content-Type-Options: nosniff
Set-Cookie: datr=XSraUWaFBXw77lQ6vXR6utiI; expires=Wed, 08-Jul-2015 02:56:29 GMT; path=/; domain=.facebook.com; httponly
Content-Type: text/html; charset=utf-8
X-FB-Debug: uPnmroZoHqj/wGG1MB02Zzi5aU6Hlg2EMjlp+VCnD6Y=
Date: Mon, 08 Jul 2013 02:56:29 GMT
Connection: keep-alive
Content-Length: 0

How can I fix this situation and let users navigate using plain HTTP?

Thanks for your answers and corrections, and sorry for my delay in answering

(translation notes: "La red es inaccesible" = "Network is unreachable")

After disabling IPv6 and reboot, curl results remain the same.

alumno@Usuario:/usr/bin$ sudo sysctl -p
[sudo] password for alumno: 
net.ipv6.conf.all.disable_ipv6 = 1
net.ipv6.conf.default.disable_ipv6 = 1
net.ipv6.conf.lo.disable_ipv6 = 1

alumno@Usuario:/usr/bin$ curl -I http://www.facebook.com
curl: (7) Failed to connect to 2a03:2880:2110:cf07:face:b00c:0:1: La red es inaccesible
alumno@Usuario:/usr/bin$ curl -I https://www.facebook.com
HTTP/1.1 302 Found
Location: http://www.facebook.com/unsupportedbrowser
P3P: CP="Facebook does not have a P3P policy. Learn why here: http://fb.me/p3p"
X-Content-Type-Options: nosniff
Set-Cookie: datr=OqLaUaYiZdlz-h8tFxRV_4yf; expires=Wed, 08-Jul-2015 11:27:54 GMT; path=/; domain=.facebook.com; httponly
Content-Type: text/html; charset=utf-8
X-FB-Debug: 0SAZyJncyia1ASFHyLekiqAji2eEFFYbvxPltd0w/xU=
Date: Mon, 08 Jul 2013 11:27:54 GMT
Connection: keep-alive
Content-Length: 0
3
  • please try curl or wget and post the error message here.
    – mnagel
    Jul 6, 2013 at 1:23
  • Hmm, it's trying to connect to an IPv6 address. We can try disabling IPv6 and see what error curl gives us. Can you do sudo sh -c "echo '\nnet.ipv6.conf.all.disable_ipv6 = 1\nnet.ipv6.conf.default.disable_ipv6 = 1\nnet.ipv6.conf.lo.disable_ipv6 = 1' >> /etc/sysctl.conf" (note, that's all on one line; it's one command), then so sudo sysctl -p, then try curl again.
    – Alaa Ali
    Jul 8, 2013 at 6:29
  • I'm facing the same situation here with a netbook exactly like yours ;) The thing is that after upgrade ubuntu I wanted to clean certain preinstalled packages with Computer Janitor and I think that that broke my network config. Have you solved that issue after all? Please contact me at juanmartindiaz at msn.com Thanks!
    – user259451
    Mar 18, 2014 at 9:18

3 Answers 3

0

Double check that you have no proxy installed.

Dash Home > Search for "Network" > Go to Network proxy > set to "None" > click "Apply system wide"

If you are still having problems, check if UncomplicatedFirewall is active.

sudo ufw status

If so, allow port 80.

sudo ufw allow 80
0

I have the same issue on Ubuntu desktop 18.04.

enviroment: Vintrual Box 5.2.44 r139111 (Qt5.6.2) Host Windows 10 bridged network on VM The VM is more than a 1 old and I use it daily for labbing. No changes made to the VM or the host (updates etc) that I am ware off.

Things I tried with no luck!:

  • Disabled IPv6 on the Physical NIC on the Win 10 host
  • Disabled IPv6 on the Nerwork profile on enp3s01 NIC
  • Enabled link-local only IPv6 IP
  • checked system proxy env (none applied)
  • checked Browser proxy and/or any proxy plug-in (none applied)
  • rebooted the Host and the Ubuntu VM several times -forced apt-get update with IPv4
  • UFW disabled
  • changed the IP from static to DHCP

Symptoms: -curl, wget elinks, links, FF all work fine with HTTPS resorces but no HTTP traffic. -PCAP shows SYN send for HTTP sites but no response with SYN-ACK.

Workaround: I pointed the Ubuntu a HTTP proxy to gain Internet connectivy on HTTP resources/applications :)

-J

1
  • The contents of my /etc/network/interfaces only had this: auto lo iface lo inet loopack The setting were defined only in the Ubuntu Desktop Wired profile settings. I removed the profile and created a new profile and this got the issue sorted for me.
    – Jan Turba
    Dec 10, 2020 at 8:46
-1

Your Browsers like Firefox and Chrome contain a list of many https website with hsts enabled on it. The list is called hsts list so this list allows user to be protected from ssl stripping attacks so anyone in your network can't sniff your content and it remains encrypted on the fly. So the websites with hsts are only able to open with https and even if you try typing http they will redirect you to https.And if some tries to attack the browser won't let you open these websites and show you error.

1
  • You can try flushing iptables and then save the new flushed rules and try then. >> #iptables -X >> #iptables -F >> #iptables-save > /etc/network/iptables.rules
    – J. white
    Jul 18, 2016 at 5:46

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .