# PS3 WPA-PSK-TKIP wireless help

## techprophet

Hi, I found this guide for getting WPA working on the PS3, but when I get to the 

```

iwpriv eth0 set_alg 2

```

part I get the following errors:

```

ioctl32(iwpriv:7599): Unknown cmd fd(3) cmd(00008be0){t:8b;sz:0} arg(ff9a72b8) on socket:[7349]

Interface doesn't accept private ioctl

set_alg (8BE0): Invalid argument

```

iwpriv eth0 outputs the following:

```

eth0        Available private ioctls :

              set_alg               (8BE0) : set    1 int    & get    0

              get_alg               (8BE1) : set    0        & get   32 char

```

The command 'fd' does not appear to exist on the LiveCD (which is where I was running this). 

Does anyone know how to fix this?

----------

## techprophet

Anyone have a clue?

I read somewhere that wpa_supplicant doesn't work with PPC64. Does it work on the LiveCD of Gentoo PPC64?

----------

## techprophet

Got it to work. The guide mentioned above works on a fresh Gentoo install on my PS3. It just won't work on the LiveCD.

----------

## pesche

Would you mind sharing which kernel version and sources you use?

I cannot get WPA to work here.

----------

## techprophet

I will look, not sure ATM, but it was the one on the LiveCD that was available in July of this year.

I am using WPA-PSK TKIP (not WPA2 for clarification). I will look when I get back

----------

## Raniz

Just created a small init-script to use with this method. If your wireless interface should have a different name than eth0 you can just change the name of the init-script and the config-file, the script will adjust automaticly.

/etc/init.d/net.eth0

```
#!/sbin/runscript

opts="start stop restart"

IFCONFIG=/sbin/ifconfig

IWPRIV=/sbin/iwpriv

IWCONFIG=/sbin/iwconfig

IFACE="${SVCNAME#*.}"

depend() {

    need localmount

    after bootmisc hostname net.lo

}

# char* interface_device(char *IFACE)

#

# Gets the base device of the interface

# Can handle $IFACE:1 and $IFACE.1

# Which returns $IFACE in this case

start() {

    ebegin "Bringing $IFACE up"

    $IFCONFIG $IFACE up

    eend $?

    ebegin "Associating with $SSID"

    $IWPRIV $IFACE set_alg $ALG

    $IWCONFIG $IFACE key "s:$KEYPHRASE"

    $IWCONFIG $IFACE essid $SSID

    eend $?

    ebegin "Starting dhcp service on $IFACE"

    dhcpcd $IFACE

    eend $?

}

stop() {

    ebegin "Stopping dhcp service on $IFACE"

    dhcpcd -k $IFACE

    eend $?

    ebegin "Bringing $IFACE down"

    ifconfig $IFACE down

    eend $?

}
```

/etc/conf.d/net.eth0

```

# The SSID of the wireless network to connect to

SSID=""

# The encryption algorithm to use:

#   1 - WEP

#   2 - WPA-PSK (TKIP)

#   3 - WPA2-PSK (AES)

ALG=2

# The keyphrase for the network you are connecting to

KEYPHRASE=""
```

----------

