summaryrefslogtreecommitdiff
path: root/sbin/ifconfig/ifconfig.c
AgeCommit message (Collapse)Author
2013-07-16Make sure the ioctl(2) has been processed by sppp(4) before printingMartin Pieuchot
any phase error. This prevents ifconfig(8) from priting 'sppp: phase...' messages for vlan(4) interfaces attached to interfaces with a long name. A better fix should be cooked because various pseudo-interfaces still use the same set of ioctl(2)s for different purposes. Issue reported by jca@, ok claudio@, jca@
2013-07-10Change the structure used in the SPPPIOSDEFS and SPPPIOGDEFS ioctlsMartin Pieuchot
to only include what is really needed. In particular stop including a "struct ifnet" and move kernel-only definition into the proper #if dance. While here remove the unused spppinfo() from ifconfig. ok guenther@, sthen@, mikeb@
2013-07-02Long passwords could not be replaced completely with shorterAlexander Bluhm
passwords. ioctl(SIOCGVH) fills the carpr_key with the old value. strlcpy() overwrites only the beginning of the key. Add a bzero() to clear the rest. Testing Jan Klemkow; OK florian@ mpf@
2013-05-31Correct the range checks in ifconfig properly for vhid, advbase and advskew.YASUOKA Masahiko
Clarify about the ranges in the man page. ok mpf mcbride
2013-04-25fix format string; found while scaning the tree for time_t/ino_t problems;Otto Moerbeek
ok deraadt@ krw@
2013-04-19remove comment about "make gcc happy" for variables which WERE beingTheo de Raadt
used uninitialized... clean up time related variables too for 2038++ ok millert
2013-04-03handle larger time_t types; toss some unused codeTheo de Raadt
ok guenther
2012-12-04add group support back (for the ramdisk version)Theo de Raadt
spotted by rpe and sthen; ok krw
2012-12-04only needs sys/types.h not sys/param.hTheo de Raadt
2012-11-23Display hardmtu value when "ifconfig hwfeatures" is used.Stuart Henderson
Looks fine reyk@ ok mikeb@
2012-09-06move pkcs5_pbkdf5 function to libutil so everybody can play with itTed Unangst
ok deraadt jsing matthew
2012-08-21Reverse the name and meaning of the IFXF_INET6_PRIVACY interfaceAlexander Bluhm
flag. It is now called IFXF_INET6_NOPRIVACY. So IPv6 privacy addresses are on by default without resetting the flag during ifconfig down/up. OK stsp@, sperreault@ (who wrote the same diff)
2012-04-15fix a leakJonathan Gray
ok krw@
2012-02-02add netflow v9/ipfix support to pflow(4).Sebastian Benoit
large parts written by Florian Obser (florian -at- narrans -dot- de). feedback from sperreault@ gollo@ sthen@ ok from gollo@ dlg@ henning@
2011-12-04Cleanup recently removed flags from ifconfig.c and its manpage.Christiano F. Haesbaert
ok jmc@ mikeb@
2011-11-26Tie the 802.1p (CoS) value in vlan(4) with the new prio scheme in pf.Christiano F. Haesbaert
When transmitting through vlan(4), it will now use the prio value in pf packet header. When receiving, we save the incoming Cos in the same place, this gives us the hability to preserve the CoS value across two different vlan interfaces. This kills the SIOC[GS]VLANPRIO ioctls and removes the corresponding buttons from ifconfig(8). ok henning@ claudio@ mcbride@
2011-11-02Expose if_capabilities to userland so that ifconfig can display theChristiano F. Haesbaert
device hardware features. Tune ifconfig to show them with 'hwfeatures' argument. While here, kill some old unused capabilities and respect 80 columns in brconfig.h. ok mcbride@, henning@, mpf@.
2011-09-19kill prototypes for long removed functions, Rafael Sadowski <rafael atHenning Brauer
sizeofvoid.org>
2011-08-21Remove old wpapsk entries. Cleanup casts and use timerclear.Christiano F. Haesbaert
ok mcbride
2011-07-09rmove rotten netatalk bitsHenning Brauer
2011-05-26Don't provide an af hint to getaddrinfo in settunnel(), this functionStuart Henderson
already checks that families of source and destination addresses match and that's all we need. This allows "ifconfig foo tunnel 1::1 2::2" syntax rather than requiring "ifconfig foo inet6 tunnel 1::1 2::2", which in turn allows hostname.if files to create an IPv4-in-IPv6 tunnel without games with shell escapes. ok dcoppa@, seems ok todd@, "Yes, yes and yes" claudio@
2011-03-23use the define for max rdomain with tunneldomain as wellJonathan Gray
ok claudio@
2011-03-13Add a way to enable/disable Wake On LAN with ifconfig.Stefan Sperling
ok deraadt
2011-03-01Introduce a dummy function in the SMALL case to digest arguments likeClaudio Jeker
"rdomain", "description", etc. so that the ifconfig on ramdisk is able to parse hostname.if files on updates. OK deraadt@
2011-02-170-4095 inclusive is the correct (12 bit) vlan rangeCamiel Dobbelaar
ok henning claudio miod
2010-11-09when setting the rdomain, use the same define as the kernelJonathan Gray
for the maximum route-id instead of a currently incorrect number ok claudio@
2010-11-01add support for (full length only) hex keys to the wpakey code. for theTheo de Raadt
remainder of the 4.8->4.9 transition, alias wpapsk to wpakey (since it swings both ways) ok damien halex tedu
2010-10-18Add wpakey/-wpakey options. This was originally written by halex andTheo de Raadt
has gone many times around now (it is smaller now). man page diff coming soon. Fits onto the media that need it. ok halex
2010-07-03Fix the naming of interfaces and variables for rdomains and rtablesPhilip Guenthe
and make it possible to bind sockets (including listening sockets!) to rtables and not just rdomains. This changes the name of the system calls, socket option, and ioctl. After building with this you should remove the files /usr/share/man/cat2/[gs]etrdomain.0. Since this removes the existing [gs]etrdomain() system calls, the libc major is bumped. Written by claudio@, criticized^Wcritiqued by me
2010-07-02make lint a bit happierTheo de Raadt
2010-06-26Add a way to enable and set the keepalive parameters for gre(4).Claudio Jeker
OK deraadt, reyk
2010-06-07Oups, an unused prototype sneaked into ifconfig. Found by jsg@Claudio Jeker
2010-06-04Merge interface flags and xflags before printing them. So it is possible toClaudio Jeker
see if a interface is using the INET6_PRIVACY or is MPLS enabled. If xflags uses more then 16 flags something else must be figured out. OK stsp@ deraadt@
2010-06-03Stop requiring the 'inet6' keyword when the 'autoconfprivacy' option is used.Stefan Sperling
Simplifies enabling autoconf privacy from hostname.if files. A line such as 'rtsol autoconfprivacy' will now work, as documented in ifconfig(8). Pointed out by steven@. ok deraadt@ steven@ todd@
2010-05-28Add mpls/-mpls commands to enable MPLS label switching on an interface.Claudio Jeker
2010-05-06Print the link state for devices not having if_media support by looking atClaudio Jeker
ifdata->ifi_link_state. Don't print in case of a unknown linkstate since some devices (lo0) just have none. OK sthen, dlg, blambert
2010-04-06Simple implementation of RFC4941, "Privacy Extensions for StatelessStefan Sperling
Address Autoconfiguration in IPv6". For those among us who are paranoid about broadcasting their MAC address to the IPv6 internet. Man page help from jmc, testing by weerd, arc4random API hints from djm. ok deraadt, claudio
2010-04-03On the random MAC address also turn off the 'local administered' bit,Theo de Raadt
since it is our intent to deceive. Prompted by weerd. ok ckuethe
2010-04-02randomized mac addresses, avaliable via 'ifconfig $if lladdr random'.Theo de Raadt
Note that not all device drivers do the work of the SIOCSIFLLADDR ioctl correctly, but this is just more reason to get them fixed. ok beck kettenis
2010-01-10s/setpriority/setifpriority/ to eliminate a conflict with setpriority()Philip Guenthe
To quote henning, 'ok gcc'
2009-12-22re-adding a group that exists is not an errorTheo de Raadt
ok claudio
2009-12-14make ifconfig return with failure of bridge_rule; ok claudioTheo de Raadt
2009-12-14use strtonum() instead of atoi(). idea from Vladimir Kirillov, but hadTheo de Raadt
to rewrite it because it was another mangled diff in mail. When will people learn that the tabs and spaces are important?
2009-12-09off by one in carp configuration; found by parfait, ok jsgTheo de Raadt
2009-11-22Merge brconfig into ifconfig. It is annoying that it is impossible to doClaudio Jeker
ifconfig bridge0 add em0 add gif0 add vether0 up instead you need to ifconfig bridge0 create brconfig bridge0 add em0 add gif0 add vether0 up This is working for everything now but we may do some changes when needed. Manpages and startup scripts are following soon. OK deraadt@, henning@
2009-11-22Fix ifconfig -a vs. ifconfig -A and make ifconfig without any arg behaveClaudio Jeker
like ifconfig -a by setting the aflag to 1. Found with and OK deraadt@
2009-11-21Add new option tunneldomain to ifconfig to specify the routing tableClaudio Jeker
to be used for sending out gre/gif encoded packets. OK deraadt@, henning@
2009-06-19after long discussion with many...Henning Brauer
ifconfig <if> inet6 used to print all inet6 addresses, and last not least the installer relies on that behaviour. so don't. to turn inet6 on again you have to assign any inet6 address or run rtsol. nobody happy about this asymmetry, but that is the best we could come up with for now.
2009-06-14enable support for deferring the packet that creates a state so that yourDavid Gwynne
sync peers are able to get the states before the replies. previously there was a race where the reply could hit a partner firewall before it had the state for it, which caused the reply to get processed by the ruleset which probably would drop it. this behaviour is off by default because it does delay packets, which is only wanted in active-active firewalls or when an upstream router is slow to learn that you're moved the active member of the pfsync cluster. it also uses memory keeping the packets in the kernel. use "ifconfig pfsync0 defer" to enable it, "ifconfig pfsync0 -defer" to disable. tested by sthen@ who loves it. he's got manpage changes coming up for me.
2009-06-11remove unused variableCharles Longeau
ok claudio@