merge wireless.example into net.example, #174282
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
DIR = /etc/conf.d
|
||||
FILES = localmount net.example wireless.example
|
||||
FILES = localmount net.example
|
||||
|
||||
TOPDIR = ..
|
||||
include $(TOPDIR)/default.mk
|
||||
|
@@ -111,8 +111,145 @@
|
||||
# ifconfig support is a one shot script - wpa_supplicant is daemon that
|
||||
# scans, assoicates and re-configures if assocation is lost.
|
||||
# wpa_supplicant is preferred
|
||||
# See wireless.example for details about using ifconfig for wireless
|
||||
####################################
|
||||
# HINTS
|
||||
#
|
||||
# Most users will just need to set the following options
|
||||
# key_ESSID1="s:yourkeyhere enc open" # s: means a text key
|
||||
# key_ESSID2="aaaa-bbbb-cccc-dd" # no s: means a hex key
|
||||
# preferred_aps="'ESSID1' 'ESSID2'"
|
||||
#
|
||||
# Clear? Good. Now configure your wireless network below
|
||||
|
||||
####################################
|
||||
# SETTINGS
|
||||
# Hard code an ESSID to an interface - leave this unset if you wish the driver
|
||||
# to scan for available Access Points
|
||||
# I would only set this as a last resort really - use the preferred_aps
|
||||
# setting at the bottom of this file
|
||||
#essid_eth0='foo'
|
||||
|
||||
# Some drivers/hardware don't scan all that well. We have no control over this
|
||||
# but we can say how many scans we want to do to try and get a better sweep of
|
||||
# the area. The default is 1.
|
||||
#scans_eth0="1"
|
||||
|
||||
#Channel can be set (1-14), but defaults to 3 if not set.
|
||||
#
|
||||
# The below is taken verbatim from the BSD wavelan documentation found at
|
||||
# http://www.netbsd.org/Documentation/network/wavelan.html
|
||||
# There are 14 channels possible; We are told that channels 1-11 are legal for
|
||||
# North America, channels 1-13 for most of Europe, channels 10-13 for France,
|
||||
# and only channel 14 for Japan. If in doubt, please refer to the documentation
|
||||
# that came with your card or access point. Make sure that the channel you
|
||||
# select is the same channel your access point (or the other card in an ad-hoc
|
||||
# network) is on. The default for cards sold in North America and most of Europe
|
||||
# is 3; the default for cards sold in France is 11, and the default for cards
|
||||
# sold in Japan is 14.
|
||||
#channel_eth0="3"
|
||||
|
||||
# Setup any other config commands. This is basically the ifconfig argument
|
||||
# without the ifconfig $iface.
|
||||
#ifconfig_eth0=""
|
||||
# You can do the same per ESSID too.
|
||||
#ifconfig_ESSID=""
|
||||
|
||||
# Seconds to wait until associated. The default is to wait 10 seconds.
|
||||
# 0 means wait indefinitely. WARNING: this can cause an infinite delay when
|
||||
# booting.
|
||||
#associate_timeout_eth0="5"
|
||||
|
||||
# Define a WEP key per ESSID or MAC address (of the AP, not your card)
|
||||
# The encryption type (open or restricted) must match the
|
||||
# encryption type on the Access Point.
|
||||
# To set a hex key, prefix with 0x
|
||||
#key_ESSID="0x12341234123412341234123456"
|
||||
# or you can use strings. Passphrase IS NOT supported
|
||||
#key_ESSID="foobar"
|
||||
#key_ESSID="foobar"
|
||||
|
||||
# WEP key for the AP with MAC address 001122334455
|
||||
#mac_key_001122334455="foobar"
|
||||
|
||||
# You can also override the interface settings found in /etc/conf.d/net
|
||||
# per ESSID - which is very handy if you use different networks a lot
|
||||
#config_ESSID="dhcp"
|
||||
#routes_ESSID=
|
||||
#fallback_ESSID=
|
||||
|
||||
# Setting name/domain server causes /etc/resolv.conf to be overwritten
|
||||
# Note that if DHCP is used, and you want this to take precedence then
|
||||
# please put -R in your dhcpcd options
|
||||
#dns_servers_ESSID="192.168.0.1 192.168.0.2"
|
||||
#dns_domain_ESSID="some.domain"
|
||||
#dns_search_path_ESSID="search.this.domain search.that.domain"
|
||||
# Please check the man page for resolv.conf for more information
|
||||
# as domain and search (searchdomains) are mutually exclusive and
|
||||
# searchdomains takes precedence
|
||||
|
||||
# You can also set any of the /etc/conf.d/net variables per MAC address
|
||||
# incase you use Access Points with the same ESSID but need different
|
||||
# networking configs. Below is an example - of course you use the same
|
||||
# method with other variables
|
||||
#config_001122334455="dhcp"
|
||||
#dns_servers_001122334455="192.168.0.1 192.168.0.2"
|
||||
|
||||
# Map a MAC address to an ESSID
|
||||
# This is used when the Access Point is not broadcasting it's ESSID
|
||||
# WARNING: This will override the ESSID being broadcast due to some
|
||||
# Access Points sending an ESSID even when they have been configured
|
||||
# not to!
|
||||
# Change 001122334455 to the MAC address and ESSID to the ESSID
|
||||
# it should map to
|
||||
#mac_essid_001122334455="ESSID"
|
||||
|
||||
# This lists the preferred ESSIDs to connect to in order
|
||||
# ESSID's can contain any characters here as they must match the broadcast
|
||||
# ESSID exactly.
|
||||
# Surround each ESSID with the " character and seperate them with a space
|
||||
# If the first ESSID isn't found then it moves onto the next
|
||||
# If this isn't defined then it connects to the first one found
|
||||
#preferred_aps="'ESSID 1' 'ESSID 2'"
|
||||
|
||||
# You can also define a preferred_aps list per interface
|
||||
#preferred_aps_eth0="'ESSID 3' 'ESSID 4'"
|
||||
|
||||
# You can also say whether we only connect to preferred APs or not
|
||||
# Values are "any", "preferredonly", "forcepreferred", "forcepreferredonly"
|
||||
# and "forceany"
|
||||
# "any" means it will connect to visible APs in the preferred list and then
|
||||
# any other available AP
|
||||
# "preferredonly" means it will only connect to visible APs in the preferred
|
||||
# list
|
||||
# "forcepreferred" means it will forceably connect to APs in order if it does
|
||||
# not find them in a scan
|
||||
# "forcepreferredonly" means it forceably connects to the APs in order and
|
||||
# does not bother to scan
|
||||
# "forceany" does the same as forcepreferred + connects to any other
|
||||
# available AP
|
||||
# Default is "any"
|
||||
#associate_order="any"
|
||||
#associate_order_eth0="any"
|
||||
|
||||
# You can define blacklisted Access Points in the same way
|
||||
#blacklist_aps="'ESSID 1' 'ESSID 2'"
|
||||
#blacklist_aps_eth0="'ESSID 3' 'ESSID 4'"
|
||||
|
||||
# If you have more than one wireless card, you can say if you want
|
||||
# to allow each card to associate with the same Access Point or not
|
||||
# Values are "yes" and "no"
|
||||
# Default is "yes"
|
||||
#unique_ap="yes"
|
||||
#unique_ap_eth0="yes"
|
||||
|
||||
# IMPORTANT: preferred_only, blacklisted_aps and unique_ap only work when
|
||||
# essid_eth0 is not set and your card is capable of scanning
|
||||
|
||||
# NOTE: preferred_aps list ignores blacklisted_aps - so if you have
|
||||
# the same ESSID in both, well, you're a bit silly :p
|
||||
|
||||
##################################################
|
||||
# wpa_supplicant
|
||||
# emerge net-wireless/wpa-supplicant
|
||||
# Wireless options are held in /etc/wpa_supplicant/wpa_supplicant.conf
|
||||
# Console the wpa_supplicant.conf.example that is installed in
|
||||
|
@@ -1,190 +0,0 @@
|
||||
# /etc/conf.d/wireless:
|
||||
# Global wireless config file for net.* rc-scripts
|
||||
|
||||
##############################################################################
|
||||
# HINTS
|
||||
##############################################################################
|
||||
# see net.example for using ESSID in variable names
|
||||
#
|
||||
# Most users will just need to set the following options
|
||||
# key_ESSID1="s:yourkeyhere enc open" # s: means a text key
|
||||
# key_ESSID2="aaaa-bbbb-cccc-dd" # no s: means a hex key
|
||||
# preferred_aps="'ESSID1' 'ESSID2'"
|
||||
#
|
||||
# Clear? Good. Now configure your wireless network below
|
||||
#############################################################################
|
||||
|
||||
##############################################################################
|
||||
# SETTINGS
|
||||
##############################################################################
|
||||
# Hard code an ESSID to an interface - leave this unset if you wish the driver
|
||||
# to scan for available Access Points
|
||||
# I would only set this as a last resort really - use the preferred_aps
|
||||
# setting at the bottom of this file
|
||||
#essid_eth0='foo'
|
||||
|
||||
# Some drivers/hardware don't scan all that well. We have no control over this
|
||||
# but we can say how many scans we want to do to try and get a better sweep of
|
||||
# the area. The default is 1.
|
||||
#scans_eth0="1"
|
||||
|
||||
#Channel can be set (1-14), but defaults to 3 if not set.
|
||||
#
|
||||
# The below is taken verbatim from the BSD wavelan documentation found at
|
||||
# http://www.netbsd.org/Documentation/network/wavelan.html
|
||||
# There are 14 channels possible; We are told that channels 1-11 are legal for
|
||||
# North America, channels 1-13 for most of Europe, channels 10-13 for France,
|
||||
# and only channel 14 for Japan. If in doubt, please refer to the documentation
|
||||
# that came with your card or access point. Make sure that the channel you
|
||||
# select is the same channel your access point (or the other card in an ad-hoc
|
||||
# network) is on. The default for cards sold in North America and most of Europe
|
||||
# is 3; the default for cards sold in France is 11, and the default for cards
|
||||
# sold in Japan is 14.
|
||||
#channel_eth0="3"
|
||||
|
||||
# Setup any other config commands. This is basically the ifconfig argument
|
||||
# without the ifconfig $iface.
|
||||
#ifconfig_eth0=""
|
||||
# You can do the same per ESSID too.
|
||||
#ifconfig_ESSID=""
|
||||
|
||||
# Seconds to wait until associated. The default is to wait 10 seconds.
|
||||
# 0 means wait indefinitely. WARNING: this can cause an infinite delay when
|
||||
# booting.
|
||||
#associate_timeout_eth0="5"
|
||||
|
||||
# Define a WEP key per ESSID or MAC address (of the AP, not your card)
|
||||
# The encryption type (open or restricted) must match the
|
||||
# encryption type on the Access Point.
|
||||
# To set a hex key, prefix with 0x
|
||||
#key_ESSID="0x12341234123412341234123456"
|
||||
# or you can use strings. Passphrase IS NOT supported
|
||||
#key_ESSID="foobar"
|
||||
#key_ESSID="foobar"
|
||||
|
||||
# WEP key for the AP with MAC address 001122334455
|
||||
#mac_key_001122334455="foobar"
|
||||
|
||||
# You can also override the interface settings found in /etc/conf.d/net
|
||||
# per ESSID - which is very handy if you use different networks a lot
|
||||
#config_ESSID="dhcp"
|
||||
#routes_ESSID=
|
||||
#fallback_ESSID=
|
||||
|
||||
# Setting name/domain server causes /etc/resolv.conf to be overwritten
|
||||
# Note that if DHCP is used, and you want this to take precedence then
|
||||
# please put -R in your dhcpcd options
|
||||
#dns_servers_ESSID="192.168.0.1 192.168.0.2"
|
||||
#dns_domain_ESSID="some.domain"
|
||||
#dns_search_path_ESSID="search.this.domain search.that.domain"
|
||||
# Please check the man page for resolv.conf for more information
|
||||
# as domain and search (searchdomains) are mutually exclusive and
|
||||
# searchdomains takes precedence
|
||||
|
||||
# You can also set any of the /etc/conf.d/net variables per MAC address
|
||||
# incase you use Access Points with the same ESSID but need different
|
||||
# networking configs. Below is an example - of course you use the same
|
||||
# method with other variables
|
||||
#config_001122334455="dhcp"
|
||||
#dns_servers_001122334455="192.168.0.1 192.168.0.2"
|
||||
|
||||
# Map a MAC address to an ESSID
|
||||
# This is used when the Access Point is not broadcasting it's ESSID
|
||||
# WARNING: This will override the ESSID being broadcast due to some
|
||||
# Access Points sending an ESSID even when they have been configured
|
||||
# not to!
|
||||
# Change 001122334455 to the MAC address and ESSID to the ESSID
|
||||
# it should map to
|
||||
#mac_essid_001122334455="ESSID"
|
||||
|
||||
# This lists the preferred ESSIDs to connect to in order
|
||||
# ESSID's can contain any characters here as they must match the broadcast
|
||||
# ESSID exactly.
|
||||
# Surround each ESSID with the " character and seperate them with a space
|
||||
# If the first ESSID isn't found then it moves onto the next
|
||||
# If this isn't defined then it connects to the first one found
|
||||
#preferred_aps="'ESSID 1' 'ESSID 2'"
|
||||
|
||||
# You can also define a preferred_aps list per interface
|
||||
#preferred_aps_eth0="'ESSID 3' 'ESSID 4'"
|
||||
|
||||
# You can also say whether we only connect to preferred APs or not
|
||||
# Values are "any", "preferredonly", "forcepreferred", "forcepreferredonly"
|
||||
# and "forceany"
|
||||
# "any" means it will connect to visible APs in the preferred list and then
|
||||
# any other available AP
|
||||
# "preferredonly" means it will only connect to visible APs in the preferred
|
||||
# list
|
||||
# "forcepreferred" means it will forceably connect to APs in order if it does
|
||||
# not find them in a scan
|
||||
# "forcepreferredonly" means it forceably connects to the APs in order and
|
||||
# does not bother to scan
|
||||
# "forceany" does the same as forcepreferred + connects to any other
|
||||
# available AP
|
||||
# Default is "any"
|
||||
#associate_order="any"
|
||||
#associate_order_eth0="any"
|
||||
|
||||
# You can define blacklisted Access Points in the same way
|
||||
#blacklist_aps="'ESSID 1' 'ESSID 2'"
|
||||
#blacklist_aps_eth0="'ESSID 3' 'ESSID 4'"
|
||||
|
||||
# If you have more than one wireless card, you can say if you want
|
||||
# to allow each card to associate with the same Access Point or not
|
||||
# Values are "yes" and "no"
|
||||
# Default is "yes"
|
||||
#unique_ap="yes"
|
||||
#unique_ap_eth0="yes"
|
||||
|
||||
# IMPORTANT: preferred_only, blacklisted_aps and unique_ap only work when
|
||||
# essid_eth0 is not set and your card is capable of scanning
|
||||
|
||||
# NOTE: preferred_aps list ignores blacklisted_aps - so if you have
|
||||
# the same ESSID in both, well, you're a bit silly :p
|
||||
|
||||
|
||||
##############################################################################
|
||||
# ADVANCED CONFIGURATION
|
||||
#
|
||||
# Two functions can be defined which will be called surrounding the
|
||||
# associate function. The functions are called with the interface
|
||||
# name first so that one function can control multiple adapters.
|
||||
#
|
||||
# The return values for the preassociate function should be 0
|
||||
# (success) to indicate that configuration or deconfiguration of the
|
||||
# interface can continue. If preassociate returns a non-zero value, then
|
||||
# interface configuration will be aborted.
|
||||
#
|
||||
# The return value for the postassociate function is ignored
|
||||
# since there's nothing to do if it indicates failure.
|
||||
|
||||
#preassociate() {
|
||||
# # The below adds two configuration variables leap_user_ESSID
|
||||
# # and leap_pass_ESSID. When they are both confiugred for the ESSID
|
||||
# # being connected to then we run the CISCO LEAP script
|
||||
#
|
||||
# local user pass
|
||||
# eval user=\"\$\{leap_user_${ESSIDVAR}\}\"
|
||||
# eval pass=\"\$\{leap_pass_${ESSIDVAR}\}\"
|
||||
#
|
||||
# if [ -n "${user}" -a -n "${pass}" ]; then
|
||||
# if [ ! -x /opt/cisco/bin/leapscript ]; then
|
||||
# eend "For LEAP support, please emerge net-misc/cisco-aironet-client-utils"
|
||||
# return 1
|
||||
# fi
|
||||
# einfo "Waiting for LEAP Authentication on \"${ESSID}\""
|
||||
# if /opt/cisco/bin/leapscript ${user} ${pass} | grep -q 'Login incorrect'; then
|
||||
# ewarn "Login Failed for ${user}"
|
||||
# return 1
|
||||
# fi
|
||||
# fi
|
||||
#
|
||||
# return 0
|
||||
#}
|
||||
|
||||
#postassociate() {
|
||||
# # This function is mostly here for completeness... I haven't
|
||||
# # thought of anything nifty to do with it yet ;-)
|
||||
# # Return 0 always
|
||||
# return 0
|
||||
#}
|
Reference in New Issue
Block a user