[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: How to share the Internet with Linux and an iPad by Wi-Fi?



Hi :)

I need some help.

PPPoE is still ok, but the WLAN adapter LED doesn't flash.
Below are the new edited /etc/network/interfaces, 
/etc/hostapd/hostapd.conf, /etc/dnsmasq.conf and the
untouched /etc/resolv.conf.

>From the cardboard box of the WLAN USB thingy:

"sempre
Wireless Lan 11N 300MB USB Adaptor
Specifications:
Complies with IEEE802.11b/g/n, IEEE802.3, IEEE802.3u standards
Supports three Mode: Ad hoc Mode, Infrastructure Mode, Soft AP
Supports Cisco CCS V1.0,2.0,3.0 standard
Supports QoS 802.11e,WMM
Provides 64/128 bit WEP ,WPA,WPA2,802.1X and 802.11i encryption security
Supports simplify Wi-Fi network setup WPS function
Supports external WPS button
Supports USB1.1 and USB2.0 interface, plug and play
Supports Wireless Roaming
Max. 300 Mbps transmission speed"

Regards,
Ralf

root@oz:~# hwinfo --usb
10: USB 00.0: 0000 Unclassified device
  [Created at usb.122]
  Unique ID: cLrx.pHbvpxhVmw2
  Parent ID: k4bc.MrJLBLcWB9F
  SysFS ID: /devices/pci0000:00/0000:00:13.5/usb1/1-2/1-2:1.0
  SysFS BusID: 1-2:1.0
  Hardware Class: unknown
  Model: "Realtek RTL8191S WLAN Adapter"
  Hotplug: USB
  Vendor: usb 0x0bda "Realtek Semiconductor Corp."
  Device: usb 0x8172 "RTL8191S WLAN Adapter"
  Revision: "2.00"
  Serial ID: "00e04c000001"
  Driver: "r8712u"
  Driver Modules: "r8712u"
  Device File: wlan0
  Speed: 480 Mbps
  HW Address: 00:0a:eb:22:ef:b3
  Module Alias: "usb:v0BDAp8172d0200dc00dsc00dp00icFFiscFFipFF"
  Driver Info #0:
    Driver Status: r8712u is active
    Driver Activation Cmd: "modprobe r8712u"
  Config Status: cfg=new, avail=yes, need=no, active=unknown
  Attached to: #4 (Hub)



++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++



root@oz:~# cat /etc/network/interfaces
# This file describes the network interfaces available on your system
# and how to activate them. For more information, see interfaces(5).

# The loopback network interface
auto lo
iface lo inet loopback

auto dsl-provider
iface dsl-provider inet ppp
pre-up /sbin/ifconfig eth0 up # line maintained by pppoeconf
provider dsl-provider

auto eth0
iface eth0 inet manual

# WLAN
allow-hotplug wlan0
iface wlan0 inet static
address 192.168.10.24
netmask 255.255.255.0



++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++



root@oz:~# cat /etc/hostapd/hostapd.conf
# /usr/share/doc/hostapd/examples/hostapd.conf.gz

interface=wlan0

# hostapd event logger configuration
logger_syslog=-1
logger_syslog_level=2
logger_stdout=-1
logger_stdout_level=2

# Dump file for state information (on SIGUSR1)
dump_file=/tmp/hostapd.dump

# Interface for separate control program.
ctrl_interface=/var/run/hostapd

# By default, hostapd is configured to use gid 0 (root).
#ctrl_interface_group=wheel
ctrl_interface_group=0

##### IEEE 802.11 related configuration
#######################################

# SSID to be used in IEEE 802.11 management frames
# http://www.webopedia.com/TERM/S/SSID.html
ssid=test

#country_code=US

# (default: 0 = disabled)
#ieee80211d=1

# Operation mode (a = IEEE 802.11a, b = IEEE 802.11b, g = IEEE 802.11g,
# Default: IEEE 802.11b
#hw_mode=a

# Channel number (IEEE 802.11)
channel=60

# Beacon interval in kus (1.024 ms)
beacon_int=100

#
dtim_period=2
max_num_sta=255
rts_threshold=2347
fragm_threshold=2346
macaddr_acl=0

# bit 0 = Open System Authentication
# bit 1 = Shared Key Authentication (requires WEP)
auth_algs=3

# 1 = send empty (length=0) SSID in beacon and ignore probe request for
#     broadcast SSID
# 2 = clear SSID (ASCII 0), but keep the original length (this may be
required
#     with some clients that do not support empty SSID) and ignore probe
#     requests for broadcast SSID
ignore_broadcast_ssid=0

#
wmm_enabled=1

# Low priority / AC_BK = background
#wmm_ac_bk_cwmin=4
wmm_ac_bk_cwmin=5
wmm_ac_bk_cwmax=10
wmm_ac_bk_aifs=7
wmm_ac_bk_txop_limit=0
wmm_ac_bk_acm=0
# Note: for IEEE 802.11b mode: cWmin=5 cWmax=10

# Normal priority / AC_BE = best effort
wmm_ac_be_aifs=3
#wmm_ac_be_cwmin=4
wmm_ac_bk_cwmin=5
#wmm_ac_be_cwmax=10
wmm_ac_be_cwmax=7
wmm_ac_be_txop_limit=0
wmm_ac_be_acm=0
# Note: for IEEE 802.11b mode: cWmin=5 cWmax=7

# High priority / AC_VI = video
wmm_ac_vi_aifs=2
#wmm_ac_vi_cwmin=3
wmm_ac_vi_cwmin=4
#wmm_ac_vi_cwmax=4
wmm_ac_vi_cwmax=5
wmm_ac_vi_txop_limit=94
wmm_ac_vi_acm=0
# Note: for IEEE 802.11b mode: cWmin=4 cWmax=5 txop_limit=188

# Highest priority / AC_VO = voice
wmm_ac_vo_aifs=2
#wmm_ac_vo_cwmin=2
wmm_ac_vo_cwmin=3
#wmm_ac_vo_cwmax=3
wmm_ac_vo_cwmax=4
wmm_ac_vo_txop_limit=47
wmm_ac_vo_acm=0
# Note: for IEEE 802.11b mode: cWmin=3 cWmax=4 burst=102

# Static WEP key configuration
wep_default_key=0
wep_key0=123456789a

##### Integrated EAP server
###################################################
# http://de.wikipedia.org/wiki/Extensible_Authentication_Protocol
eap_server=0

#private_key=/etc/hostapd.server.prv

# Passphrase for private key
private_key_passwd=secret passphrase

# 0 = do not verify CRLs (default)

###############################################################################
##### WPA/IEEE 802.11i configuration
##########################################
###############################################################################

# Enable WPA. Setting this variable configures the AP to require WPA
(either
# WPA-PSK or WPA-RADIUS/EAP based on other configuration). For WPA-PSK,
either
# wpa_psk or wpa_passphrase must be set and wpa_key_mgmt must include
WPA-PSK.
# For WPA-RADIUS/EAP, ieee8021x must be set (but without dynamic WEP
keys),
# RADIUS authentication server must be configured, and WPA-EAP must be
included
# in wpa_key_mgmt.
# This field is a bit field that can be used to enable WPA (IEEE
802.11i/D3.0)
# and/or WPA2 (full IEEE 802.11i/RSN):
# bit0 = WPA
# bit1 = IEEE 802.11i/RSN (WPA2) (dot11RSNAEnabled)
wpa=1

# WPA pre-shared keys for WPA-PSK. This can be either entered as a
256-bit
# secret in hex format (64 hex digits), wpa_psk, or as an ASCII
passphrase
# (8..63 characters) that will be converted to PSK. This conversion uses
SSID
# so the PSK changes when ASCII passphrase is used and the SSID is
changed.
# wpa_psk (dot11RSNAConfigPSKValue)
# wpa_passphrase (dot11RSNAConfigPSKPassPhrase)
wpa_psk=0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef
wpa_passphrase=secret passphrase

# Optionally, WPA PSKs can be read from a separate text file (containing
list
# of (PSK,MAC address) pairs. This allows more than one PSK to be
configured.
# Use absolute path name to make sure that the files can be read on
SIGHUP
# configuration reloads.
#wpa_psk_file=/etc/hostapd.wpa_psk

# Set of accepted key management algorithms (WPA-PSK, WPA-EAP, or both).
The
# entries are separated with a space. WPA-PSK-SHA256 and WPA-EAP-SHA256
can be
# added to enable SHA256-based stronger algorithms.
# (dot11RSNAConfigAuthenticationSuitesTable)
wpa_key_mgmt=WPA-PSK WPA-EA
# Pairwise cipher for WPA (v1) (default: TKIP)
#wpa_pairwise=TKIP CCMP
# Pairwise cipher for RSN/WPA2 (default: use wpa_pairwise value)
#rsn_pairwise=CCMP

# Time interval for rekeying GTK (broadcast/multicast encryption keys)
in
# seconds. (dot11RSNAConfigGroupRekeyTime)
#wpa_group_rekey=600

# Rekey GTK when any STA that possesses the current GTK is leaving the
BSS.
# (dot11RSNAConfigGroupRekeyStrict)
#wpa_strict_rekey=1

# Time interval for rekeying GMK (master key used internally to generate
GTKs
# (in seconds).
#wpa_gmk_rekey=86400

# Maximum lifetime for PTK in seconds. This can be used to enforce
rekeying of
# PTK to mitigate some attacks against TKIP deficiencies.
#wpa_ptk_rekey=600

# Enable IEEE 802.11i/RSN/WPA2 pre-authentication.

##### Wi-Fi Protected Setup (WPS)
#############################################

# WPS state
# 0 = WPS disabled (default)

##### Multiple BSSID support
##################################################
#
# Above configuration is using the default interface (wlan#, or
multi-SSID VLAN
# interfaces). Other BSSIDs can be added by using separator 'bss' with
# default interface name to be allocated for the data packets of the new
BSS.



++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++



root@oz:~# cat /etc/dnsmasq.conf
# Configuration file for dnsmasq.
# "/usr/sbin/dnsmasq --help" "man 8 dnsmasq"

# Change this line if you want dns to get its upstream servers from
# somewhere other that /etc/resolv.conf
#resolv-file=

# If you don't want dnsmasq to read /etc/resolv.conf or any other
# file, getting its servers from this file instead (see below), then
# uncomment this.
#no-resolv

# If you don't want dnsmasq to poll /etc/resolv.conf or other resolv
# files for changes and re-read them then uncomment this.
#no-poll

# If you want dnsmasq to change uid and gid to something other
# than the default, edit the following lines.
#user=
#group=

# If you don't want dnsmasq to read /etc/hosts, uncomment the
# following line.
#no-hosts
# or if you want it to read another file, as well as /etc/hosts, use
# this.
#addn-hosts=/etc/banner_add_hosts

# Set this (and domain: see below) if you want to have a domain
# automatically added to simple names in a hosts-file.
#expand-hosts

# Specify a subnet which can't be used for dynamic address allocation,
# is available for hosts with matching --dhcp-host lines. Note that
# dhcp-host declarations will be ignored unless there is a dhcp-range
# of some type for the subnet in question.
# In this case the netmask is implied (it comes from the network
# configuration on the machine running dnsmasq) it is possible to give
# an explicit netmask instead.
dhcp-range=192.168.10.24,static

# Enable the address given for "judge" in /etc/hosts
# to be given to a machine presenting the name "judge" when
# it asks for a DHCP lease.
#dhcp-host=judge

# Send options to hosts which ask for a DHCP lease.
# See RFC 2132 for details of available options.
#dhcp-option=

# Enable dnsmasq's built-in TFTP server
#enable-tftp

# Set the cachesize here.
#cache-size=150

# If you want to disable negative caching, uncomment this.
#no-negcache

# Normally responses which come form /etc/hosts and the DHCP lease
# file have Time-To-Live set as zero, which conventionally means
# do not cache further. If you are happy to trade lower load on the
# server for potentially stale date, you can set a time-to-live (in
# seconds) here.
#local-ttl=

# Include a another lot of configuration options.
#conf-file=/etc/dnsmasq.more.conf
#conf-dir=/etc/dnsmasq.d



++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++



root@oz:~# ls /etc/reso*
/etc/resolv.conf  /etc/resolvconf.conf  /etc/resolv.conf.pppd-backup.ppp0

/etc/resolvconf:
update.d  update-libc.d

root@oz:~# cat /etc/resolv.conf
# Generated by resolvconf
nameserver 127.0.0.1
nameserver 62.109.123.196
nameserver 213.191.74.18

root@oz:~# cat /etc/resolvconf.conf
# Configuration for resolvconf(8)
# See resolvconf.conf(5) for details

resolv_conf=/etc/resolv.conf
# If you run a local name server, you should uncomment the below line
and
# configure your subscribers configuration files below.
#name_servers=127.0.0.1

root@oz:~# cat /etc/resolv.conf.pppd-backup.ppp0
# Generated by NetworkManager


Reply to: