Revision 566b1e7f
Added by sbeaver about 10 years ago
usr/local/www/diag_logs_settings.php | ||
---|---|---|
223 | 223 |
gettext("Save") |
224 | 224 |
)); |
225 | 225 |
|
226 |
// General logging section ------------------------------------------------ |
|
227 | 226 |
$section = new Form_Section('General Logging Options'); |
228 | 227 |
|
229 | 228 |
$section->addInput(new Form_Checkbox( |
... | ... | |
313 | 312 |
$section->addInput(new Form_Button( |
314 | 313 |
'resetlogs', |
315 | 314 |
'Reset Log Files' |
316 |
))->addClass("btn-danger btn-xs")->setHelp('Clears all local log files and reinitializes them as empty logs. This also restarts the DHCP daemon. Use the Save button first if you have made any setting changes.');
|
|
315 |
))->addClass('btn-danger btn-xs')->setHelp('Clears all local log files and reinitializes them as empty logs. This also restarts the DHCP daemon. Use the Save button first if you have made any setting changes.');
|
|
317 | 316 |
|
318 | 317 |
$form->add($section); |
319 |
|
|
320 |
// Remote logging section ------------------------------------------------ |
|
321 | 318 |
$section = new Form_Section('Remote Logging Options'); |
319 |
$section->addClass('toggle-remote'); |
|
322 | 320 |
|
323 |
$sourceips = get_possible_traffic_source_addresses(false); |
|
324 |
|
|
325 |
$selected = ""; |
|
326 |
|
|
327 |
foreach ($sourceips as $sa) { |
|
328 |
$rllist[$sa['value']] = $sa['name']; |
|
329 |
|
|
330 |
if (!link_interface_to_bridge($sa['value']) && ($sa['value'] == $pconfig['sourceip'])) |
|
331 |
$selected = $sa['value']; |
|
332 |
} |
|
321 |
$section->addInput(new Form_Checkbox( |
|
322 |
'enable', |
|
323 |
'Enable Remote Logging', |
|
324 |
'Send log messages to remote syslog server', |
|
325 |
$pconfig['enable'] |
|
326 |
))->toggles('.toggle-remote .panel-body .form-group:not(:first-child)'); |
|
333 | 327 |
|
334 | 328 |
$section->addInput(new Form_Select( |
335 | 329 |
'sourceip', |
336 | 330 |
'Source Address', |
337 |
$selected,
|
|
338 |
$rllist
|
|
331 |
link_interface_to_bridge($pconfig['sourceip']) ? null : $pconfig['sourceip'],
|
|
332 |
get_possible_traffic_source_addresses(false)
|
|
339 | 333 |
))->setHelp($remoteloghelp); |
340 | 334 |
|
341 | 335 |
$section->addInput(new Form_Select( |
... | ... | |
345 | 339 |
array('ipv4' => 'IPv4', 'ipv6' => 'IPv6') |
346 | 340 |
))->setHelp('This option is only used when a non-default address is chosen as the source above. This option only expresses a preference; If an IP address of the selected type is not found on the chosen interface, the other type will be tried.'); |
347 | 341 |
|
348 |
$section->addInput(new Form_Checkbox( |
|
349 |
'enable', |
|
350 |
'Enable Remote Logging', |
|
351 |
'Send log messages to remote syslog server', |
|
352 |
$pconfig['enable'] |
|
353 |
))->toggles('.toggle-remote'); |
|
354 |
|
|
355 | 342 |
// Group colapses/appears based on 'enable' checkbox above |
356 | 343 |
$group = new Form_Group('Remote log servers'); |
357 |
$group->addClass('toggle-remote', 'collapse'); |
|
358 |
|
|
359 |
if ($pconfig['enable']) |
|
360 |
$group->addClass('in'); |
|
361 | 344 |
|
362 | 345 |
$group->add(new Form_Input( |
363 | 346 |
'remoteserver', |
... | ... | |
385 | 368 |
|
386 | 369 |
$section->add($group); |
387 | 370 |
|
388 |
$group = new Form_Group(''); |
|
389 |
$group->addClass('toggle-remote', 'collapse'); |
|
390 |
|
|
391 |
if ($pconfig['enable']) |
|
392 |
$group->addClass('in'); |
|
393 |
|
|
371 |
$group = new Form_Group('Remote Syslog Contents'); |
|
394 | 372 |
$group->add(new Form_Checkbox( |
395 | 373 |
'system', |
396 |
'',
|
|
374 |
null,
|
|
397 | 375 |
'System Events', |
398 | 376 |
$pconfig['system'] |
399 | 377 |
)); |
400 | 378 |
|
401 | 379 |
$group->add(new Form_Checkbox( |
402 | 380 |
'filter', |
403 |
'',
|
|
381 |
null,
|
|
404 | 382 |
'Firewall Events', |
405 | 383 |
$pconfig['filter'] |
406 | 384 |
)); |
407 | 385 |
|
408 | 386 |
$group->add(new Form_Checkbox( |
409 | 387 |
'dhcp', |
410 |
'',
|
|
388 |
null,
|
|
411 | 389 |
'DHCP service events', |
412 | 390 |
$pconfig['dhcp'] |
413 | 391 |
)); |
414 | 392 |
|
415 | 393 |
$group->add(new Form_Checkbox( |
416 | 394 |
'portalauth', |
417 |
'',
|
|
395 |
null,
|
|
418 | 396 |
'Portal Auth events', |
419 | 397 |
$pconfig['portalauth'] |
420 | 398 |
)); |
421 | 399 |
|
422 | 400 |
$group->add(new Form_Checkbox( |
423 | 401 |
'vpn', |
424 |
'',
|
|
402 |
null,
|
|
425 | 403 |
'VPN (PPTP, IPsec, OpenVPN) events', |
426 | 404 |
$pconfig['vpn'] |
427 | 405 |
)); |
428 | 406 |
|
429 | 407 |
$group->add(new Form_Checkbox( |
430 | 408 |
'apinger', |
431 |
'',
|
|
409 |
null,
|
|
432 | 410 |
'Gateway Monitor events', |
433 | 411 |
$pconfig['apinger'] |
434 | 412 |
)); |
435 | 413 |
|
436 | 414 |
$group->add(new Form_Checkbox( |
437 | 415 |
'relayd', |
438 |
'',
|
|
416 |
null,
|
|
439 | 417 |
'Server Load Balancer events', |
440 | 418 |
$pconfig['relayd'] |
441 | 419 |
)); |
442 | 420 |
|
443 | 421 |
$group->add(new Form_Checkbox( |
444 | 422 |
'hostapd', |
445 |
'',
|
|
423 |
null,
|
|
446 | 424 |
'Wireless events', |
447 | 425 |
$pconfig['hostapd'] |
448 | 426 |
)); |
449 | 427 |
|
450 |
$group->setHelp('<strong>Note</strong>' . 'syslog sends UDP datagrams to port 514 on the specified remote syslog server, unless another port is specified. Be sure to set syslogd on the remote server to accept syslog messages frompfSense.'); |
|
428 |
$group->setHelp('syslog sends UDP datagrams to port 514 on the specified remote '. |
|
429 |
'syslog server, unless another port is specified. Be sure to set syslogd on '. |
|
430 |
'the remote server to accept syslog messages from pfSense.'); |
|
451 | 431 |
|
452 | 432 |
$section->add($group); |
453 | 433 |
|
454 | 434 |
$form->add($section); |
455 | 435 |
print $form; |
456 | 436 |
|
457 |
include("foot.inc"); ?>
|
|
437 |
include("foot.inc"); |
Also available in: Unified diff
dig_settings updated
Switched to my master branch, updated with pull from SH fork, updated
tab array and committed.
This version should correspond to the head version but with revised tab
array.