Some misconceptions... iwconfig is a tool to configure your card in a certain way, or to see how it is connected. It's not the right tool for what you want.
If I understand you right, you want to find an open access point somewhere to connect. There are a couple of programs that allow you to do that, such as kismet (what I use), ethereal, or wellenreiter. You can take advantage of AP's that are inadvertantly open, if the owner doesn't know doesn't know better or doesn't care about the security risks, or ones which are deliberately open. You usually get an DHCP address and can use the owber's network - DHCP does all the routing stuff so it will be right automatically. Again, some people have their AP's open on purpose, most have just left it open, and it's up to you to consider an open door an invitation to come in or not.
Hope it helps,
mlp
|