Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
O
OpnSense
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Kulya
OpnSense
Commits
7f1c91f7
Commit
7f1c91f7
authored
Dec 01, 2015
by
Franco Fichtner
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
settings: fix old sshd reload trigger bug
parent
6dcbac7a
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
10 additions
and
17 deletions
+10
-17
system_advanced_admin.php
src/www/system_advanced_admin.php
+10
-17
No files found.
src/www/system_advanced_admin.php
View file @
7f1c91f7
...
...
@@ -93,18 +93,6 @@ if ($_POST) {
}
}
if
(
$_POST
[
'passwordauth'
]
==
'yes'
)
{
$config
[
'system'
][
'ssh'
][
'passwordauth'
]
=
'enabled'
;
}
elseif
(
isset
(
$config
[
'system'
][
'ssh'
][
'passwordauth'
]))
{
unset
(
$config
[
'system'
][
'ssh'
][
'passwordauth'
]);
}
if
(
$_POST
[
'sshdpermitrootlogin'
]
==
"yes"
)
{
$config
[
'system'
][
'ssh'
][
'permitrootlogin'
]
=
"enabled"
;
}
elseif
(
isset
(
$config
[
'system'
][
'ssh'
][
'permitrootlogin'
]))
{
unset
(
$config
[
'system'
][
'ssh'
][
'permitrootlogin'
]);
}
ob_flush
();
flush
();
...
...
@@ -213,14 +201,17 @@ if ($_POST) {
unset
(
$config
[
'system'
][
'ssh'
][
'port'
]);
}
if
(
!
isset
(
$_POST
[
'sshdpermitrootlogin'
])
&&
isset
(
$config
[
'system'
][
'ssh'
][
'permitrootlogin'
]))
{
$sshd_permitrootlogin
=
isset
(
$config
[
'system'
][
'ssh'
][
'permitrootlogin'
]);
if
(
$_POST
[
'sshdpermitrootlogin'
])
{
$config
[
'system'
][
'ssh'
][
'permitrootlogin'
]
=
true
;
}
elseif
(
isset
(
$config
[
'system'
][
'ssh'
][
'permitrootlogin'
]))
{
unset
(
$config
[
'system'
][
'ssh'
][
'permitrootlogin'
]);
}
if
((
$sshd_enabled
!=
$config
[
'system'
][
'ssh'
][
'enabled'
])
||
(
$sshd_passwordauth
!=
$config
[
'system'
][
'ssh'
][
'passwordauth'
]
)
||
(
$sshd_passwordauth
!=
isset
(
$config
[
'system'
][
'ssh'
][
'passwordauth'
])
)
||
(
$sshd_port
!=
$config
[
'system'
][
'ssh'
][
'port'
])
||
(
$
pconfig
[
'system'
][
'ssh'
][
'permitrootlogin'
]
!=
isset
(
$config
[
'system'
][
'ssh'
][
'permitrootlogin'
]))
)
{
(
$
sshd_permitrootlogin
!=
isset
(
$config
[
'system'
][
'ssh'
][
'permitrootlogin'
]))
)
{
$restart_sshd
=
true
;
}
...
...
@@ -522,8 +513,10 @@ endif; ?>
}
?>
/>
<strong>
<?=
gettext
(
"Permit root user login"
);
?>
</strong>
<br
/>
<?=
gettext
(
"Root login is generally discouraged. It is advised "
);
?>
<?=
gettext
(
"to log in via another user and switch to root afterwards."
);
?>
<?=
gettext
(
'Root login is generally discouraged. It is advised '
.
'to log in via another user and switch to root afterwards.'
)
?>
</td>
</tr>
<tr>
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment