Merge pull request #1562 from phil-davis/usr-review1
Code Style sbin tmp usr
Bits and pieces from sbin tmp and usr but not yet usr/local/www
pfSsh.php readline function return value
This just looks wrong. But I guess the code path never comes through here because function readline() already exists in the environment of this script.
Update help to current config structure, touch up text while here. Fixes #4492
Fixes #4340 encode username same as with password to avoid issues with special chars.
Teach ufslabels.sh to deal with DESTDIR, useful on installation
Improve a bit sh syntax and fix it for multiple swap devices
Fix sed syntax, -i requires a space before the parameter. Also fix regex to find swap device
Put the value of password under double quotes(") to avoid issues with special characters in passwords. Ticket #4177
Prevent echo to insert a newline(\n) at the secret string. Fixes #4177
Remove debug code
Fixes #4177 convert password to base64 to be submitted to avoid issues with special chars in shell and HTTP GET parameter passing. Probably should add POST support to fcgicli.
Make this code less memory hungry and fix route command generation
Fix lineup of copyright lines
and module names and other bits of formatting and typos in headercomment sections.
Welcome 2015
Encode space to avoid rejecting users with spaces in username
Remove these booting settings since are useless
Fix ovpn-linkup for tun + topology subnet case setting router as ifconfig_local envvaar when route_vpn_gateway and ifconfig_remote are both not defined. Keep using 5th parameter as a seatbelt in last case. While I'm here, improve sh syntax. It should fix #3968
Change copyright statement to reflect reality
clean up text
Simplify a bit ppp-linkup syntax
Fix awk syntax, it fixes #3813
Fix filename
Bring in proper gmirror support for the GUI and notifications.Made a general gmirror library to perform various gmirror tasks and get information, using some of the former widget logic to start. Updated widget to use this new code.Added a Diag > GEOM Mirrors page that displays information about existing mirrors and perform various management tasks. Current actions include rebuilding a drive, forgetting disconnected mirror drives, insert/remove, deactivate/activate, clearing medatada. It's now possible to use the GUI to rebuild a failed mirror by performing a forget, then insert action to replace a missing/dead drive....
Single quoting $password breaks getting the value from the variable.
No spaces between variable assignments in sh
Add missing closing quotes
Correct missing parenthesis. Reported-by: https://forum.pfsense.org/index.php?topic=75120.0
Trigger rc.newwaipv6 as well from pppoe when it gets an inet6 config
Use env var provided by openvpn to determine if it's tun or tap, it should fix #3475
Do not call rc.newwanip when pppoe gets a v6 ip.
Remove PBI scripts since it'll be installed dynamically by tools
Fix an obvious typo on var name
Sync pbi_create with pcbsd, add required functions.sh
ports ntp moved to sbin, follow
Move also tls-verify to fcgicli to avoid forking php process. Maybe even this should be done as a plugin to avoid overhead of forking.
Migrate openvpn authentication to use fcgicli rather than forking a php process. Maybe should could consider to write a short library todo this
Fix ufslabels.sh logic to avoid trying to convert slices which are already using appropriate labels. Fixes #3207
Related to Ticket #3045 avoid races in the ntpdate_sync_one script due to killall returning without the process really exiting.
Use ntpdate from ports also and obsolete base one
Improve sh syntax using ${} for all variables
Fix test
Fix exec bits.
Fix #3113, fix multiple english spell errors s/seperet/separat/
Add a script that can automatically convert a user's fstab over to ufs labels. Useful for full installs to avoid issues with device numbering (e.g. ad0 changes to ad4 or da0 to ad2, or in the future case, adX to adaX)
Make sure file has content before call route delete
Respect 'States' option from Advanced/Misc
- Respect this option and do not clean states when it's configured- Create /etc/rc.kill_states to be easier to check $config
It helps ticket #2887
Remove redundant call
Improve ppp-linkdown:
- Improve readability giving name to parameter variables- Add path for all command calls
Fix default route deletion
Fix indent
Initialize array to silence warnings on foreach
Declare $config as global before interactive PHP shell command evaluation. Fixes #808
Ticket #1629 Another round of fixes related to state clearing
Make sure ntpd creates ntpd.pid file at bootup
Use the better -Fs modifies to pf to kill the states by interface. Also kill both sides on an interface when -k needs to be used
pfctl -b is gone just use std tools of pfctl
Avoid duplicating /32 suffix on 3rd ppp-linkdown parameter (local-ip). It should fix #2700
Sync PBI scripts
Be a little more verbose when starting the NTP daemon
Try a little harder to clear the states for the old PPP gateway
Sync pbi tools
Sync with upstream pbi tools
Update pbi_create to current code from pc-bsd
Use awk instead of grep, this works on a v4 PPPoE connection for me. Need to verify that it works for 3G too.Redmine ticket #2458
Fix exec bit for usr/local/sbin/openvpn.attributes.sh
Import OpenVPN cisco style radius attributes applying policy to logged in users. Feature #2100
Move the SIM Pin and APN settings to the modem setup since we need these only once.
Fix the PinReady command not found error.Add a log command to show where you are dialing to.
Switch to ntpd from ports, add Services > NTP to select interfaces for binding. Respect old ntp settings in the process.
Skip a few pieces of code earlier. Perform file test on dhcpd logs.
Add a few micro optimizations, bail out when the file does not exist.
Update the link script to parse the arguments 6 and 7 differently.Previously mpd supplied the dns1 string as $6 and the IP as $7. It is now a single argument $6.Apparently this changed somewhere so parse the IP out of there into the correct nameserver file....
This command works better with Huawei modems. Needs more testing
Make sure we don't accidentaly clobber the v4 dns servers with empty fields from v6
On its own, ntpd does not sync fast enough at bootup, so bring back the ntpdate sync but improve it so it can't get stuck forever.
Fix syntax here too in case we need to revive it.
Make the ppp-linkup script understand both address families.
Add a dhcpleases monitor to the DHCPv6 server which will trigger automatic creation of routes into the routing table so that prefix delegation will just work.Redmine ticket #2347
Rather use -c to check for line count, we then dont have to deal with extra whitespaces
The function split() is replaced by the function explode(). Starting with PHP 5.3 this is deprecated and with version 6 gone.Replacing it surpresses all the warnings
Adding missing file
Adding pbi_ suite of tools
Adding pbi_create
Bind the state killing to the interface they should kill the states so that it does not impact other services like in #1421
Make sure this does not operate on empty parameters, and also log when removing states.
Just break states based on the remote host ip and not with localip. The later might be the same as address used by other services and might interrupt them
Use the new change to be less distuptive
Put a netmask of /32 to all parameters of -k/-K/-b of pfctl to avoid any issues.
Kill states from the previous ip the link had on all mpd consumers. Resolves #1629
Fix test for tun device, -f fails because it's a char device, not a regular file. -e works.
Do not add an automatic gateway on openvpn tap case since its only the netmask.
Disable state killing in VPN down scripts.
Fix ovpn-linkup so it writes out the proper gateway IP in all cases.(For some reason -n wasn't working properly, plus $5 is the right parameter for the remote IP here)
Reorder instructions and do not reload dns if its not allowed from the dns allow override setting.
Remove static routes that are added for dns servers when allow override is allowed when a ppp interface goes down. Code borrowed from dhclient-script.
Ticket #1408. Honor the allow override settings even for ppp devices.
Rework ntpdate_sync_once.sh, so it makes sure ntp/ntpdate/itself are not running before trying to sync time, and then launch ntpd at the end for time sync (last commit was premature)
Don't unconditionally start ntpd after doing ntpdate, it might be disabled.
Send ntpdate output to syslog