Config: Add SSSD exclude_users and exclude_groups
Add configuration functionality to allow sssd exclude_users, and exclude_groups configuration options. These options are only applicable when scope=all. Refer to man sssd-session-recording(5)
This commit is contained in:
parent
2fe72717b2
commit
c48e7f69d1
1 changed files with 33 additions and 2 deletions
|
|
@ -398,6 +398,8 @@ class SssdConfig extends React.Component {
|
||||||
this.state = {
|
this.state = {
|
||||||
scope: "",
|
scope: "",
|
||||||
users: "",
|
users: "",
|
||||||
|
exclude_users: "",
|
||||||
|
exclude_groups: "",
|
||||||
groups: "",
|
groups: "",
|
||||||
submitting: false,
|
submitting: false,
|
||||||
};
|
};
|
||||||
|
|
@ -456,8 +458,20 @@ class SssdConfig extends React.Component {
|
||||||
const obj = {};
|
const obj = {};
|
||||||
obj.session_recording = {};
|
obj.session_recording = {};
|
||||||
obj.session_recording.scope = this.state.scope;
|
obj.session_recording.scope = this.state.scope;
|
||||||
|
switch (this.state.scope) {
|
||||||
|
case "all":
|
||||||
|
obj.session_recording.exclude_users = this.state.exclude_users;
|
||||||
|
obj.session_recording.exclude_groups = this.state.exclude_groups;
|
||||||
|
break;
|
||||||
|
case "none":
|
||||||
|
break;
|
||||||
|
case "some":
|
||||||
obj.session_recording.users = this.state.users;
|
obj.session_recording.users = this.state.users;
|
||||||
obj.session_recording.groups = this.state.groups;
|
obj.session_recording.groups = this.state.groups;
|
||||||
|
break;
|
||||||
|
default:
|
||||||
|
break;
|
||||||
|
}
|
||||||
this.confSave(obj);
|
this.confSave(obj);
|
||||||
e.preventDefault();
|
e.preventDefault();
|
||||||
}
|
}
|
||||||
|
|
@ -499,6 +513,23 @@ class SssdConfig extends React.Component {
|
||||||
/>
|
/>
|
||||||
</FormGroup>
|
</FormGroup>
|
||||||
</>}
|
</>}
|
||||||
|
{this.state.scope === "all" &&
|
||||||
|
<>
|
||||||
|
<FormGroup label={_("Exclude Users")}>
|
||||||
|
<TextInput
|
||||||
|
id="exclude_users"
|
||||||
|
value={this.state.exclude_users}
|
||||||
|
onChange={exclude_users => this.setState({ exclude_users })}
|
||||||
|
/>
|
||||||
|
</FormGroup>
|
||||||
|
<FormGroup label={_("Exclude Groups")}>
|
||||||
|
<TextInput
|
||||||
|
id="exclude_groups"
|
||||||
|
value={this.state.exclude_groups}
|
||||||
|
onChange={exclude_groups => this.setState({ exclude_groups })}
|
||||||
|
/>
|
||||||
|
</FormGroup>
|
||||||
|
</>}
|
||||||
<ActionGroup>
|
<ActionGroup>
|
||||||
<Button
|
<Button
|
||||||
id="btn-save-sssd-conf"
|
id="btn-save-sssd-conf"
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue