mirror of
https://github.com/SELinuxProject/selinux
synced 2024-12-17 19:54:32 +00:00
libselinux: formally deprecate security_compute_user()
It was originally marked for deprecation back in Feb 2020,
commit a41dfeb55d
("libselinux: deprecate security_compute_user(),
update man pages"), but the attribute was not added at the time.
Signed-off-by: Stephen Smalley <stephen.smalley.work@gmail.com>
Acked-by: Petr Lautrbach <lautrbach@redhat.com>
This commit is contained in:
parent
b41174207c
commit
9b83fe3d99
@ -263,9 +263,15 @@ extern int security_compute_member_raw(const char * scon,
|
||||
* These interfaces are deprecated. Use get_ordered_context_list() or
|
||||
* one of its variant interfaces instead.
|
||||
*/
|
||||
#ifdef __GNUC__
|
||||
__attribute__ ((deprecated))
|
||||
#endif
|
||||
extern int security_compute_user(const char * scon,
|
||||
const char *username,
|
||||
char *** con);
|
||||
#ifdef __GNUC__
|
||||
__attribute__ ((deprecated))
|
||||
#endif
|
||||
extern int security_compute_user_raw(const char * scon,
|
||||
const char *username,
|
||||
char *** con);
|
||||
|
@ -96,7 +96,9 @@ int security_compute_user(const char * scon,
|
||||
if (selinux_trans_to_raw_context(scon, &rscon))
|
||||
return -1;
|
||||
|
||||
IGNORE_DEPRECATED_DECLARATION_BEGIN
|
||||
ret = security_compute_user_raw(rscon, user, con);
|
||||
IGNORE_DEPRECATED_DECLARATION_END
|
||||
|
||||
freecon(rscon);
|
||||
if (!ret) {
|
||||
|
Loading…
Reference in New Issue
Block a user