Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
ruanhaishen
redis
Commits
9e5c3828
Commit
9e5c3828
authored
Jan 21, 2019
by
antirez
Browse files
ACL: setuser resetkeys implemented.
parent
2263d6e1
Changes
1
Hide whitespace changes
Inline
Side-by-side
src/acl.c
View file @
9e5c3828
...
@@ -244,7 +244,10 @@ int ACLSetUser(user *u, const char *op, ssize_t oplen) {
...
@@ -244,7 +244,10 @@ int ACLSetUser(user *u, const char *op, ssize_t oplen) {
!
strcasecmp
(
op
,
"~*"
))
!
strcasecmp
(
op
,
"~*"
))
{
{
u
->
flags
|=
USER_FLAG_ALLKEYS
;
u
->
flags
|=
USER_FLAG_ALLKEYS
;
if
(
u
->
patterns
)
listEmpty
(
u
->
patterns
);
listEmpty
(
u
->
patterns
);
}
else
if
(
!
strcasecmp
(
op
,
"resetkeys"
))
{
u
->
flags
&=
~
USER_FLAG_ALLKEYS
;
listEmpty
(
u
->
patterns
);
}
else
if
(
!
strcasecmp
(
op
,
"allcommands"
)
||
}
else
if
(
!
strcasecmp
(
op
,
"allcommands"
)
||
!
strcasecmp
(
op
,
"+@all"
))
!
strcasecmp
(
op
,
"+@all"
))
{
{
...
...
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