Changeset 20b4760 in freewrt for package/broadcom-wl-util
- Timestamp:
- Nov 1, 2006, 2:23:04 AM (19 years ago)
- Branches:
- freewrt_1_0, freewrt_2_0
- Children:
- 325a270
- Parents:
- 679f318
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
package/broadcom-wl-util/files/wireless-broadcom.pre-up
r679f318 r20b4760 59 59 wl ap 0 60 60 ;; 61 Monitor)61 monitor) 62 62 wl ap 0 63 63 wl monitor 1 … … 98 98 # 99 99 [ "$IF_WIRELESS_AFTERBURNER" ] && wl afterburner_override $IF_WIRELESS_AFTERBURNER 100 101 #102 # security "open"103 #104 [ "$IF_WIRELESS_SECURITY" = "open" ] && {105 wl wep 0106 wl ssid $IF_WIRELESS_SSID107 exit 0108 }109 110 #111 # security "wep"112 #113 [ "$IF_WIRELESS_SECURITY" = "wep" ] && {114 wl wep 1115 wl eap off116 wl wpa_auth 0117 wl wsec 1118 case "$IF_WIRELESS_AUTHORIZATION" in119 "open")120 echo "wep authorization not supported for now"121 exit 1122 ;;123 "shared")124 echo "wep authorization not supported for now"125 exit 1126 ;;127 "open+shared")128 echo "wep authorization not supported for now"129 exit 1130 ;;131 esac132 [ "$IF_WIRELESS_KEY1" ] && wl addwep 0 $IF_WIRELESS_KEY1133 [ "$IF_WIRELESS_KEY2" ] && wl addwep 1 $IF_WIRELESS_KEY2134 [ "$IF_WIRELESS_KEY3" ] && wl addwep 2 $IF_WIRELESS_KEY3135 [ "$IF_WIRELESS_KEY4" ] && wl addwep 3 $IF_WIRELESS_KEY4136 [ "$IF_WIRELESS_KEY" ] && wl primary_key $(($IF_WIRELESS_KEY-1))137 138 wl ssid $IF_WIRELESS_SSID139 exit 0140 }141 100 142 101 # … … 171 130 wl wsec $crypto_num 172 131 132 # 133 # security "open" 134 # 135 [ "$IF_WIRELESS_SECURITY" = "open" ] && { 136 wl wep 0 137 wl ssid $IF_WIRELESS_SSID 138 exit 0 139 } 140 141 # 142 # security "wep" 143 # 144 [ "$IF_WIRELESS_SECURITY" = "wep" ] && { 145 wl wep 1 146 wl eap off 147 wl wpa_auth 0 148 wl wsec 1 149 150 [ "$IF_WIRELESS_MODE" = "ap" ] && { 151 case "$IF_WIRELESS_AUTHORIZATION" in 152 open) 153 echo "This option is not supported for now" 154 exit 1 155 ;; 156 shared) 157 echo "This option is not supported for now" 158 exit 1 159 ;; 160 open+shared) 161 echo "This option is not supported for now" 162 exit 1 163 ;; 164 esac 165 [ "$IF_WIRELESS_KEY1" ] && wl addwep 0 $IF_WIRELESS_KEY1 166 [ "$IF_WIRELESS_KEY2" ] && wl addwep 1 $IF_WIRELESS_KEY2 167 [ "$IF_WIRELESS_KEY3" ] && wl addwep 2 $IF_WIRELESS_KEY3 168 [ "$IF_WIRELESS_KEY4" ] && wl addwep 3 $IF_WIRELESS_KEY4 169 [ "$IF_WIRELESS_KEY" ] && wl primary_key $(($IF_WIRELESS_KEY-1)) 170 171 wl ssid $IF_WIRELESS_SSID 172 } 173 174 [ "$IF_WIRELESS_MODE" = "sta" ] && { 175 case "$IF_WIRELESS_AUTHORIZATION" in 176 open) 177 authorization="open" 178 ;; 179 shared) 180 authorization="shared" 181 ;; 182 *) 183 authorization="open" 184 ;; 185 esac 186 187 wl join $IF_WIRELESS_SSID key $IF_WIRELESS_KEY1 amode $authorization 188 } 189 exit 0 190 } 191 173 192 # wpa rekeying 174 193 gtk_rekey=$IF_WIRELESS_WPA_GTK_REKEY … … 182 201 wl eap off 183 202 case "$IF_WIRELESS_AUTHORIZATION" in 184 "psk")203 psk) 185 204 auth=4 186 205 ;; 187 "psk2")206 psk2) 188 207 auth=128 189 208 ;; … … 202 221 ) & 203 222 } 204 205 /usr/sbin/nas -P /var/run/nas.lan.pid ${ifname:+ -l $ifname} -H 34954 -i $IFACE $nas_auth -m $auth -k "$IF_WIRELESS_WPA_KEY" -s "$IF_WIRELESS_SSID" -w $crypto_num -g $gtk_rekey & 206 exit 0 207 } 208 209 exit 0 223 [ "$IF_WIRELESS_MODE" = "ap" ] && { 224 /usr/sbin/nas -P /var/run/nas.lan.pid ${ifname:+ -l $ifname} -H 34954 -i $IFACE $nas_auth -m $auth -k "$IF_WIRELESS_WPA_KEY" -s "$IF_WIRELESS_SSID" -w $crypto_num -g $gtk_rekey & 225 } 226 227 [ "$IF_WIRELESS_MODE" = "sta" ] && { 228 # XXX Does not work for now! XXX 229 wl join $IF_WIRELESS_SSID $IF_WIRELESS_WPA_KEY wpapsk 230 } 231 exit 0 232 } 210 233 211 234 # … … 214 237 [ "$IF_WIRELESS_SECURITY" = "8021x" ] && { 215 238 case "$IF_WIRELESS_AUTHORIZATION" in 216 "wep")239 wep) 217 240 wl wpa_auth 0 218 241 /usr/sbin/nas -P /var/run/nas.lan.pid ${ifname:+ -l ${ifname}} -H 34954 -i $IFACE & 219 242 exit 0 220 243 ;; 221 "wpa")244 wpa) 222 245 auth=2 223 246 ;; 224 "wpa2")247 wpa2) 225 248 auth=64 226 249 ;;
Note:
See TracChangeset
for help on using the changeset viewer.
