Commit Graph

24592 Commits

Author SHA1 Message Date
Phil Davis
e6abcccc54 Validation of y/n answers in setlanip
At the moment the user can answer "yes" to most of the questions, but then later code only checks if the answer is "y". Thus you can type in "yes" in some places, have it accepted, but actually the negative action is taken. That is weird and will mess up people who try typing a whole string starting with "y".
With this change it makes the user type one of "y", "yes", "n", "no". When they type 1 of those, it is turned into either "y" or "n". Then the existing implementation logic all works as expected.
Hopefully this is the "final" version that fixes the behavior of the (y/n) questions.
I also included the bit at 296-297 which adds the CIDR bit-count range to the prompt, so the user can see exactly what input is valid/expected there.
Redmine issue #4100
2014-12-12 23:01:07 +05:45
Renato Botelho
38e1541b99 Update service providers xml to sync with upstream 2014-12-12 14:55:57 -02:00
Renato Botelho
3bc55eee36 Merge pull request #1383 from phil-davis/patch-10 2014-12-12 14:49:28 -02:00
Phil Davis
87657b9528 rc.initial.setlanip fix validation of CIDR within range
Currently this allows the user to input any number for the CIDR. I happened to try 44 for an IPv4 CIDR when playing.
This fixes that little bug - I think it is good to commit that first/separately so it can be identified apart from the other (y/n) checking/handling I am working on. Better to have separate commits for distinct bugs.
2014-12-12 21:04:46 +05:45
Renato Botelho
c45c6ccd8b Regenerate Turkish mo 2014-12-12 12:29:58 -02:00
Renato Botelho
019645ffe7 Update po from last pot 2014-12-12 12:28:59 -02:00
Renato Botelho
66f8965d11 Update Turkish translation file from last version available on old translation server 2014-12-12 12:27:28 -02:00
Renato Botelho
fb0495f351 Regenerate pfSense.pot 2014-12-12 12:13:54 -02:00
Renato Botelho
2e65babb16 Fix password confirmation name to make style working as expected. Fixes #3992 2014-12-12 09:17:25 -02:00
Renato Botelho
a516c81efe Merge pull request #1381 from phil-davis/patch-8 2014-12-12 08:40:14 -02:00
Phil Davis
a93bc2994b Base URL must be specified when alturlenable on
I had a 2.1.5 system that I was wondering why the dashboard always said it could not check for updates. I discovered it had "Use an unofficial server for firmware upgrades" checked, but the "Base URL" field was empty.
That can easily be checked with input validation - might as well catch dumb things like that.
I thought about making it parse the string to see if it seemed like a "valid" URL. But so many strings seem like valid URLs:
var_dump(parse_url("abc"));
array(1) {
  ["path"]=>
  string(3) "abc"
}

It seemed a bit pointless to bother - if the user puts something in then hope that it might point to something some day.
2014-12-12 10:38:38 +05:45
Renato Botelho
fcc96054a0 Split ICMP and ICMPv6 types on Firewall Rules
- Remove redundant declaration of $icmptypes and move it to a common
place (filter.inc)
- Add missing ICMP types for v4
- Add ICMPv6 types
- Adjust javascripts to show correct options depending of IP Protocol
- Hide ICMP type selection when protocol is IPv4+v6

It fixes #3389
2014-12-11 19:50:00 -02:00
Renato Botelho
c03ed2fb58 Fix indent and spaces 2014-12-11 19:49:58 -02:00
Renato Botelho
11bdc638ef Fix #4099:
- When interface is 'lo0', strpos returns 0, that is erroneously
considered false (boolean) on the test. Be more strict on strpos return
to avoid skiping lo0 ip aliases during sync.
2014-12-11 16:43:19 -02:00
Renato Botelho
986fd3d9a7 Fix #3790:
- Do not let 2 interfaces to setup the same track6 prefix id
- Show correct prefix id range for each interface
2014-12-11 15:03:50 -02:00
Renato Botelho
8d5be861fb Merge pull request #1378 from phil-davis/patch-10 2014-12-11 07:39:13 -02:00
Renato Botelho
21e7104418 Merge pull request #1379 from phil-davis/patch-11 2014-12-11 07:37:44 -02:00
Phil Davis
04c0724ed8 Improve check if no OpenVPN defined
Alternate version of https://github.com/pfsense/pfsense/pull/1376
This version retains the is_array() checks and then only does the count() if the is_array() is true.
Take whichever version you like.
2014-12-11 08:24:26 +05:45
Phil Davis
2cc10e2cde Change text and color delimiter to carat sign
To match change made in functions.inc.php
2014-12-11 07:15:09 +05:45
Phil Davis
6385c33515 Gateway Status Widget keep IP address bold
Forum: https://forum.pfsense.org/index.php?topic=85187.msg467438#msg467438

The bold is specified literally in gateways.widget.php for the gateway IP box, so we need to send it bold from here also when providing an update.
Because this now uses a "/" in the string (to terminate the bold) have to choose another delimiter between the status text and status color - picked "^" because I can't think where it will appear elsewhere in the real data.
This whole string of stuff that is returned by getstats.php back to the browser is a long string with a bunch of delimiters inside delimiters already (vertical bar separated fields, inside that comma-separated fields...) and is already subject to stuff going wrong if any of the real text in the fields contains a vertical bar or comma or... Not about to try to re-engineer all that right now!
2014-12-11 07:13:01 +05:45
jim-p
6346f188e1 Setup ddb on all platforms. On full install it will save the dump, on NanoBSD it will print to console and auto-reboot.
This way, a router running NanoBSD won't sit at a db> prompt indefinitely if it crashes.
2014-12-10 11:36:26 -05:00
Renato Botelho
b3986dd15d Merge pull request #1377 from phil-davis/patch-9 2014-12-10 13:39:51 -02:00
Phil Davis
f4d094b485 Fixup text rule should be route
This code was obviously taken from firewall rules and reused here without changing the word "rule" to "route".
2014-12-10 21:17:51 +05:45
Renato Botelho
d7563eebc7 Remove spurious '>', fixes #4091 2014-12-10 12:14:43 -02:00
Renato Botelho
b8dd129d4d Make sure this message is only displayed on console 2014-12-10 09:58:38 -02:00
Renato Botelho
76f1217188 get_failover_interface() is already called inside get_interface_ip(v6), no need to call it twice. It should fix #4089 2014-12-10 09:55:58 -02:00
Renato Botelho
9a92e2ef64 Use exit instead of return here, otherwise script's return code is always 0 and user with wrong password is authenticated 2014-12-08 19:44:53 -02:00
Renato Botelho
ae0daa804d Merge pull request #1371 from phil-davis/patch-6 2014-12-07 20:31:40 -02:00
Renato Botelho
47a122315f Merge pull request #1370 from phil-davis/patch-5 2014-12-07 20:30:30 -02:00
Phil Davis
eca5402b32 Provide success return indication from console_configure_dhcpd
Recent commit 9ea554ee5c added testing of the return status of console_configure_dhcpd() - this let a user effectively abort from doing anything if they have answered "y" to prompt_for_enable_dhcp_server() and are being asked for the start and end of the range, and then decide they do not want to proceed.
However, even when they gave good answers, status 0 was being returned. This prevented changes ever being implemented.
Redmine: https://redmine.pfsense.org/issues/4080
The fix is to return 1 at the routine end, when all is good and the code should proceed.
2014-12-07 22:41:11 +05:45
Phil Davis
2ce15f633e Standardise css list padding
for the_wall theme
2014-12-07 22:13:13 +05:45
Phil Davis
fe9273cfdf Standardise css list padding
for pfsense_ng_fs theme
2014-12-07 22:11:34 +05:45
Phil Davis
4fb660ae16 Standardise css list padding
for pfsense theme
2014-12-07 22:09:45 +05:45
Phil Davis
6e74f280a6 Standardise css list padding
for pfsense-dropdown theme
2014-12-07 22:08:02 +05:45
Phil Davis
09b095b0a5 Standardise css list padding
for nervecenter theme
2014-12-07 22:06:09 +05:45
Phil Davis
af978cb9de Standardise css list padding
for metallic theme
2014-12-07 22:04:11 +05:45
Phil Davis
04d21981f8 Standardise css list padding
for code-red theme
2014-12-07 22:01:27 +05:45
Phil Davis
66591feb74 Standardise css list padding
for _corporate
2014-12-07 21:56:55 +05:45
Renato Botelho
f3dac61c02 Merge pull request #1368 from phil-davis/patch-3 2014-12-07 13:41:30 -02:00
Renato Botelho
f060bd2a8a Merge pull request #1369 from phil-davis/patch-4 2014-12-07 13:40:41 -02:00
Phil Davis
9241d942b9 Typo CIDR in UPnP GUI page
As reported by johnpoz https://forum.pfsense.org/index.php?topic=84964.0
2014-12-07 19:10:59 +05:45
Phil Davis
0f3d668ff0 Standardise css list padding
On Status->Services, the Services Status widget when a service status is down, the red "x" button does not line up with the green "running" button in the column.
This is because listbg has:
padding-right: 16px;
But the normal listr has:
padding-right: 6px;
It seems really odd that listbg as 16 pixels right padding. I expected it to have all the same padding as listr, just with a different color.
listn and listbggrey have the same "feature" of extra padding-right.
listn does not seem to be used anywhere anyway - might as well "fix" it in case something uses it some time.
listbggrey seems to only be used by pkg_mgr_installed.php in the case when an installed package version is in advance of the online version - quite an unusual thing! Changing padding-right from 16px back to 6px is fine for that.
Then the "feature" is lso in listhdr and listhdrr - lots of examples like firewall_aliases.php have the column headings as listhdr or listhdrr, so in theory if the column is not so wide already, it will put 16px on the right after the column heading text. But the actual rows of data underneath use listr and listbg, which only specify 6px right padding. In the end it usually does not make any difference - there is space already and the browser lines it all up anyway. But it seems to me an odd difference in the css.
listtopic also has this 16px right padding thing - but it seems to be used just for text display that is not in columns, so I did not mess with that.
Changing this css fixes the lineup of the red "x" in the services status column and does not seem to break anything else. In theory it could make other things better also.
Someone who knows how the css was intended to be used could comment on this! If I have got the right idea, and these "16px" things were just a mistake from the past, then it should be checked in the css for all themes and corrected appropriately... 
I am happy to do that, once someone confirms it is the thing to do.
2014-12-07 15:32:41 +05:45
Chris Buechler
fa10244f3f Disable RC4 ciphers in lighttpd 2014-12-05 15:05:47 -06:00
Renato Botelho
56c6993c26 Call filter_configure_sync() is a better fix for #4066, as pointed by Ermal 2014-12-05 17:04:07 -02:00
Renato Botelho
6d744cc842 Fix #4066:
Make sure pf is configured before other services are restarted when WAN
IP changes. The way it was before, 'pass out' rules with route-to still
have old IP set as 'from' and some Dynamic DNS ended up not being
updated.
2014-12-05 16:20:34 -02:00
Renato Botelho
8da00522ea Add RELENG_2_2 to gitsync 2014-12-05 11:05:46 -02:00
Renato Botelho
75f65f9cb9 Merge pull request #1367 from phil-davis/patch-2 2014-12-05 11:05:08 -02:00
Phil Davis
95d045fcd7 Set text and color of Gateways Widget Status
getstats.php calls functions.inc.php get_stats(), which calls get_gatewaystats().
get_gatewaystats() now returns the text for each field and an optional color separated by "/" - "text/color" e.g. "Online/#90EE90"
Parse the the new format, separating out text and color.
If color is specified, then also set it with jQuery to css.
2014-12-05 17:54:30 +05:45
Phil Davis
beb7d9e332 Explicitly pass gateway status and color
This code was passing a whole load of html to attempt to set various properties of the Gateways Widget Status column so that it would display the new status (Online, Offline...) and in the appropriate color.
Now that I am using class=listr, the css fro listr already specifies white. Setting bgcolor in HTML does not override that.
Pass both the status text and color as ordinary text, separated by "/". The consumer of this output can do their thing with jQuery to set the color as well as text of the element.
2014-12-05 17:43:48 +05:45
Phil Davis
6404148cf3 Use proper listr class for Gateways Widget Status
The Gateways Widget Status was not using the listr class, and so it was missing the borders for the right and bottom of its box.
Use the listr class.
Then use javascript to explicitly set the background-color to match the status, overriding the white that is specified in listr.
2014-12-05 17:36:49 +05:45