Looks like no one’s replied in a while. To start the conversation again, simply ask a new question.

Automatic connection to wireless before login?

Hi all,

Can anyone tell me how to make my Mac Mini (old PowerPC version) connect to a wireless network at startup, before the user is required to log in? It is running OS X 10.5.8 with a standard configuration.

I have tried playing with the network settings, but it does not seem to associate itself with the wireless network until after a user account has logged in. (Once I do log in, though, wireless association happens quickly and normally.)

Any ideas?

Thanks!
- Essd

Mac Mini late 2005, Mac OS X (10.5.8)

Posted on Oct 15, 2009 2:25 PM

Reply
5 replies

Oct 15, 2009 4:49 PM in response to Kappy

Hi Kappy,

Yes, that is what I gathered. But my question is: can this be changed? My wired Ethernet connection works fine before a user is logged in, so I'd like to have my wireless enabled too. I know that there is authentication involved for password-protected networks, but I'd hope that this could be set somewhere in a system keychain, or something like that.

I have seen some hints that the wireless interface can get enabled before login (esp. with regard to the 802.1X authentication interface), but since I'm not planning to deploy 802.1X on my LAN, that part doesn't seem to help much.

Any ideas? Given that this is an Apple product, surely, there must an easier way than having to hack my own LaunchDaemon to call the command-line 802.11 framework.

- essd

Oct 15, 2009 7:04 PM in response to essd

I know you can activate the Ethernet port during startup so it may be possible to activate a wireless port as well, but would take some Unix know how to set that up. Not my area of expertise, but there is a group of forums on Mac Technologies of which one is the Unix forum where you may find some help.

Oct 15, 2009 8:18 PM in response to Kappy

Ugh! I was hoping to avoid having to do some UNIX hacking, but since no one else has piped up, I figured out a semi-reasonable way to do it.

In /Library/LaunchDaemons, create a file called "com.example.airport.plist" and place the following in it:

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/
PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>Debug</key>
<false/>
<key>Label</key>
<string>com.example.airport</string>
<key>KeepAlive</key>
<false/>
<key>ProgramArguments</key>
<array>
<string>/Users/YOURUSERNAMEHERE/bin/join-wifi.sh</string>
</array>
<key>RunAtLoad</key>
<true/>
</dict>
</plist>

This tells it to run the script /Users/YOURUSERNAMEHERE/bin/join-wifi.sh at start-up. Obviously, replace YOURUSERNAMEHERE with your OS X username so that this corresponds to a folder off your home directory.

Then, in your home directory, make sure that you have a "bin" folder for storing scripts. Create a file therein called join-wifi.sh that contains this:

#!/bin/bash
networksetup -setairportpower en1 on
networksetup -setairportnetwork en1 your-network-name-goes-here 'your-WPA-key-goes-here'

In this last file, replace the your-network-name-goes-here with the name of the wireless network, and replace your-WPA-key-goes-here with your wireless network's password.

The next time you reboot, it should join the wireless network automatically.

That did it for me, but I sure wish there were a more elegant solution!

- essd

Automatic connection to wireless before login?

Welcome to Apple Support Community
A forum where Apple customers help each other with their products. Get started with your Apple ID.