LinuxQuestions.org
LinuxAnswers - the LQ Linux tutorial section.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Debian
User Name
Password
Debian This forum is for the discussion of Debian Linux.

Notices



Reply
 
Search this Thread
Old 10-04-2007, 10:14 PM   #1
DittoAlex
LQ Newbie
 
Registered: Oct 2003
Posts: 23

Rep: Reputation: 15
How do I specify "security mode: open" in /etc/network/interfaces?


Debian Etch 4.0r1

I am unable to associate to my AP unless I specify "Security mode: open" with the following command
Code:
iwconfig [interface] key open
How can I add this command to my /etc/network/interfaces? I tried adding the line
Code:
wireless-key open
but that errored out due to it being a duplicate of my encryption key line,
Code:
wireless-key [key]
My /etc/network/interfaces is really very straight-forward:

Code:
iface ath0 inet dhcp
wireless-essid abcdefghij
wireless-key 1234567890
auto ath0
If it is not possible to do it through /etc/network/interfaces, perhaps I could script it to apply the 'iwconfig interface key open' command once ath0 comes up.

I asked this in the Wireless Networking forum but received no resolution and was instead directed to ask here.
 
Old 10-04-2007, 11:15 PM   #2
HappyTux
Senior Member
 
Registered: Mar 2003
Location: Nova Scotia, Canada
Distribution: Debian AMD64
Posts: 3,513

Rep: Reputation: 64
Quote:
Originally Posted by DittoAlex View Post
Debian Etch 4.0r1

I am unable to associate to my AP unless I specify "Security mode: open" with the following command
Code:
iwconfig [interface] key open
How can I add this command to my /etc/network/interfaces? I tried adding the line
Code:
wireless-key open
but that errored out due to it being a duplicate of my encryption key line,
Code:
wireless-key [key]
My /etc/network/interfaces is really very straight-forward:

Code:
iface ath0 inet dhcp
wireless-essid abcdefghij
wireless-key 1234567890
auto ath0
If it is not possible to do it through /etc/network/interfaces, perhaps I could script it to apply the 'iwconfig interface key open' command once ath0 comes up.

I asked this in the Wireless Networking forum but received no resolution and was instead directed to ask here.
Try something like this for the interfaces file using your example above.

Code:
iface ath0 inet dhcp
          wireless-essid abcdefghij
          wireless-key 1234567890
          post-up iwconfig ath0 1234567890 open
auto ath0
 
Old 10-04-2007, 11:39 PM   #3
DittoAlex
LQ Newbie
 
Registered: Oct 2003
Posts: 23

Original Poster
Rep: Reputation: 15
Quote:
Originally Posted by HappyTux View Post
Try something like this for the interfaces file using your example above.

Code:
iface ath0 inet dhcp
          wireless-essid abcdefghij
          wireless-key 1234567890
          post-up iwconfig ath0 1234567890 open
auto ath0
That worked. It got me connected, associated, and a DHCP lease. However I receive the following error messages, indicating the process could be cleaner:

Code:
iwconfig: unknown command "1234567890"
Failed to bring up ath0.
 
Old 10-04-2007, 11:58 PM   #4
farslayer
Guru
 
Registered: Oct 2005
Location: Willoughby, Ohio
Distribution: linuxdebian
Posts: 7,232
Blog Entries: 5

Rep: Reputation: 189Reputation: 189
Another Atheros how-to I saw did it this way..

Code:
# wireless 
auto ath0

# dhcp
iface ath0 inet dhcp
    pre-up /sbin/iwpriv ath0 mode 3
    pre-up /sbin/iwconfig ath0 essid "blabla" rate 54M key 14929429325878194789834632

for ath0 mode :
0 = 802.11a/b/g
1 = 802.11a
2 = 802.11b
3 = 802.11g
 
Old 10-05-2007, 12:01 AM   #5
HappyTux
Senior Member
 
Registered: Mar 2003
Location: Nova Scotia, Canada
Distribution: Debian AMD64
Posts: 3,513

Rep: Reputation: 64
Quote:
Originally Posted by DittoAlex View Post
That worked. It got me connected, associated, and a DHCP lease. However I receive the following error messages, indicating the process could be cleaner:

Code:
iwconfig: unknown command "1234567890"
Failed to bring up ath0.
Well that was me using your example key in the command perhaps you might need to put the actual key there or as it worked without having the actual key for the command I would think that you can skip the 1234567890 part entirely as the key does not seem to be needed there.
 
Old 10-05-2007, 12:07 AM   #6
DittoAlex
LQ Newbie
 
Registered: Oct 2003
Posts: 23

Original Poster
Rep: Reputation: 15
Quote:
Originally Posted by HappyTux View Post
Well that was me using your example key in the command perhaps you might need to put the actual key there or as it worked without having the actual key for the command I would think that you can skip the 1234567890 part entirely as the key does not seem to be needed there.
I did put my actual key.

I replace instances of my actual key to 1234567890 when posting in this thread.
 
Old 10-05-2007, 01:32 AM   #7
HappyTux
Senior Member
 
Registered: Mar 2003
Location: Nova Scotia, Canada
Distribution: Debian AMD64
Posts: 3,513

Rep: Reputation: 64
Quote:
Originally Posted by DittoAlex View Post
I did put my actual key.

I replace instances of my actual key to 1234567890 when posting in this thread.
Alright looking at the man page it seems that from the example there being iwconfig eth0 key open that when using the open you don't need the actual key the other examples seem to using the key string when not using open.

Code:
iwconfig eth0 key 0123-4567-89
iwconfig eth0 key [3] 0123-4567-89
iwconfig eth0 key s:password [2]
iwconfig eth0 key [2]
 
Old 10-05-2007, 02:16 AM   #8
jschiwal
Guru
 
Registered: Aug 2001
Location: Fargo, ND
Distribution: SuSE AMD64
Posts: 15,733

Rep: Reputation: 655Reputation: 655Reputation: 655Reputation: 655Reputation: 655Reputation: 655
Are you sure that the router isn't set to operate in the open.
 
Old 10-05-2007, 11:45 AM   #9
DittoAlex
LQ Newbie
 
Registered: Oct 2003
Posts: 23

Original Poster
Rep: Reputation: 15
Quote:
Originally Posted by jschiwal View Post
Are you sure that the router isn't set to operate in the open.
I'm not sure what you're asking.
 
Old 10-07-2007, 02:55 PM   #10
jschiwal
Guru
 
Registered: Aug 2001
Location: Fargo, ND
Distribution: SuSE AMD64
Posts: 15,733

Rep: Reputation: 655Reputation: 655Reputation: 655Reputation: 655Reputation: 655Reputation: 655
If the router were set up for WPA or WEP encryption, then you wouldn't have been able to connect in the clear earlier. The first post said that you could associate when you used "security mode = open". Please check your routers settings.
 
Old 10-07-2007, 11:17 PM   #11
DittoAlex
LQ Newbie
 
Registered: Oct 2003
Posts: 23

Original Poster
Rep: Reputation: 15
Quote:
Originally Posted by jschiwal View Post
If the router were set up for WPA or WEP encryption, then you wouldn't have been able to connect in the clear earlier. The first post said that you could associate when you used "security mode = open". Please check your routers settings.
Yeah, it's what I've been afraid of. My DD-WRT is fuxored
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
what is "sticky bit mode" , "SUID" , "SGID" augustus123 Linux - General 10 08-03-2012 05:40 AM
How do I specify "security mode: open" in /etc/network/interfaces? DittoAlex Linux - Wireless Networking 4 09-29-2007 03:11 PM
LXer: Displaying "MyComputer", "Trash", "Network Servers" Icons On A GNOME Desktop LXer Syndicated Linux News 0 04-02-2007 09:31 AM
Lost DHCP Lease when putting computer in "Standby" mode for a "long" time pnellesen Linux - Networking 1 01-07-2005 12:44 AM
Samba security "permissions" in DOMAIN mode tisource Linux - Networking 3 05-09-2002 10:41 PM


All times are GMT -5. The time now is 01:36 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration