Announcement

Collapse
No announcement yet.

cannot connect to site in web browser after seemingly connecting to Public WIFI

Collapse
This topic is closed.
X
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    cannot connect to site in web browser after seemingly connecting to Public WIFI

    i type 'iwlist wlan0 scan #' and can see the wifi i am trying to connect to in it's cell.

    i type 'sudo iwconfig wlan0 essid {"essid name"} enc {passphrase}' and no error is returned but i can't load Konquerer and load http://google.com.

    I can connect to this public wifi with Windows with the passphrase. It uses WEP.

    Someone suggested that maybe i have not enabled DHCP.

    I tried adding && dhclient wlan0 to the end of the iwconfig string above but it tries to load some program and fails.

    So, I need a solution where I dont need to download things from within linux, since I can never get an internet connection there. any ideas?

    #2
    Re: cannot connect to site in web browser after seemingly connecting to Public WIFI

    From "man iwconfig":
    key/enc[ryption]
    Used to manipulate encryption or scrambling keys and security mode.
    To set the current encryption key, just enter the key in hex digits as XXXX-XXXX-XXXX-XXXX or XXXXXXXX. To set a key other than the current key,
    prepend or append [index] to the key itself (this won't change which is the active key). You can also enter the key as an ASCII string by using the
    s: prefix. Passphrase is currently not supported.
    Convert your passphrase to hex IF it is possibe. (In most cases it is not, but WPA-PSK has a formula to do so: http://www.xs4all.nl/~rjoris/wpapsk.html)

    Key = PBKDF2(passphrase, ssid, 4096, 256) is how it is generated, but there is no function default in Kubuntu that allows you do do that (that I would trust to use without blowing up grub).


    For WEP keys is it less likely, but you can generate a HEX key on your passphrase and try it using this website: http://www.corecoding.com/utilities/wep2hex.php or this site: http://www.dolcevie.com/js/converter.html. The odds are it won't work.

    The problem is like asking what numbers add up to give you 1,234. Each vendor can use a different set of numbers to total 1,234.

    It would be easier to let your router generate the HEX key from the passphrase and then you can copy the hex key down and use it in your command line.
    "A nation that is afraid to let its people judge the truth and falsehood in an open market is a nation that is afraid of its people.”
    – John F. Kennedy, February 26, 1962.

    Comment


      #3
      Re: cannot connect to site in web browser after seemingly connecting to Public WIFI

      Originally posted by GreyGeek
      From "man iwconfig":
      key/enc[ryption]
      Used to manipulate encryption or scrambling keys and security mode.
      To set the current encryption key, just enter the key in hex digits as XXXX-XXXX-XXXX-XXXX or XXXXXXXX. To set a key other than the current key,
      prepend or append [index] to the key itself (this won't change which is the active key). You can also enter the key as an ASCII string by using the
      s: prefix. Passphrase is currently not supported.
      Convert your passphrase to hex IF it is possibe. (In most cases it is not, but WPA-PSK has a formula to do so: http://www.xs4all.nl/~rjoris/wpapsk.html)

      Key = PBKDF2(passphrase, ssid, 4096, 256) is how it is generated, but there is no function default in Kubuntu that allows you do do that (that I would trust to use without blowing up grub).


      For WEP keys is it less likely, but you can generate a HEX key on your passphrase and try it using this website: http://www.corecoding.com/utilities/wep2hex.php or this site: http://www.dolcevie.com/js/converter.html. The odds are it won't work.

      The problem is like asking what numbers add up to give you 1,234. Each vendor can use a different set of numbers to total 1,234.

      It would be easier to let your router generate the HEX key from the passphrase and then you can copy the hex key down and use it in your command line.
      I used the hex code from the second link your provided, and the command went through. Still, I could not connect.
      Also, I'd like to add that I am now using successfully the command 'dhclient -r wlan0' which i believe starts up the DHCP.
      Futhermore, I can connect to the access point in windows from the same location.
      Any ideas on where to go from here?


      for future reference:
      I used the hex code i generated from the 1st and 3rd links you provided. the command returned:
      'ERROR for WIRELESS REQUEST "SET ENCODE". (8B2A). SET failed on device wlan0; Invalid argument.


      Comment


        #4
        Re: cannot connect to site in web browser after seemingly connecting to Public WIFI

        The "man dhclient" reveals:
        The client normally doesn't release the current lease as it is not required by the DHCP protocol. Some cable ISPs require their clients to notify the server if they wish to release an assigned IP address. The -r flag explicitly releases the current lease, and once the lease has been released, the client exits.
        This implies that you had a lease all along and attempts to "connect" were blocked by your ISP because they had already assigned a lease to you. Check your daemon logs (K --> System --> KSystemlogs) and see if during the bootup you are given a lease which, for some reason, is dropped. IF, as the man says, your ISP doesn't drop a lease until requested to do so, your access may be blocked until the lease expires, which could be up to 24 hours, the usual default lease time.

        You could put
        #!/bin/bash
        dhclient -r wlan0
        in a text file (call it "wlan0_connect.sh") in your home account directory, mark it executable, and then have it autoexecute at KDE4 startup. (K --> Settings --> System Settings --> Startup and Shutdown --> Auto Startup)
        "A nation that is afraid to let its people judge the truth and falsehood in an open market is a nation that is afraid of its people.”
        – John F. Kennedy, February 26, 1962.

        Comment

        Working...
        X