Page Menu
Home
FreeBSD
Search
Configure Global Search
Log In
Files
F160149885
D54052.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Flag For Later
Award Token
Size
6 KB
Referenced Files
None
Subscribers
None
D54052.diff
View Options
diff --git a/sys/kern/init_main.c b/sys/kern/init_main.c
--- a/sys/kern/init_main.c
+++ b/sys/kern/init_main.c
@@ -560,7 +560,7 @@
audit_cred_kproc0(newcred);
#endif
#ifdef MAC
- mac_cred_create_swapper(newcred);
+ mac_cred_create_kproc0(newcred);
#endif
/* Create sigacts. */
p->p_sigacts = sigacts_alloc();
diff --git a/sys/security/mac/mac_cred.c b/sys/security/mac/mac_cred.c
--- a/sys/security/mac/mac_cred.c
+++ b/sys/security/mac/mac_cred.c
@@ -132,10 +132,10 @@
* processes and threads are spawned.
*/
void
-mac_cred_create_swapper(struct ucred *cred)
+mac_cred_create_kproc0(struct ucred *cred)
{
- MAC_POLICY_PERFORM_NOSLEEP(cred_create_swapper, cred);
+ MAC_POLICY_PERFORM_NOSLEEP(cred_create_kproc0, cred);
}
/*
diff --git a/sys/security/mac/mac_framework.h b/sys/security/mac/mac_framework.h
--- a/sys/security/mac/mac_framework.h
+++ b/sys/security/mac/mac_framework.h
@@ -134,7 +134,7 @@
int mac_cred_check_visible(struct ucred *cr1, struct ucred *cr2);
void mac_cred_copy(struct ucred *cr1, struct ucred *cr2);
void mac_cred_create_init(struct ucred *cred);
-void mac_cred_create_swapper(struct ucred *cred);
+void mac_cred_create_kproc0(struct ucred *cred);
void mac_cred_destroy(struct ucred *);
void mac_cred_init(struct ucred *);
diff --git a/sys/security/mac/mac_policy.h b/sys/security/mac/mac_policy.h
--- a/sys/security/mac/mac_policy.h
+++ b/sys/security/mac/mac_policy.h
@@ -167,7 +167,7 @@
typedef void (*mpo_cred_copy_label_t)(struct label *src,
struct label *dest);
typedef void (*mpo_cred_create_init_t)(struct ucred *cred);
-typedef void (*mpo_cred_create_swapper_t)(struct ucred *cred);
+typedef void (*mpo_cred_create_kproc0_t)(struct ucred *cred);
typedef void (*mpo_cred_destroy_label_t)(struct label *label);
typedef int (*mpo_cred_externalize_label_t)(struct label *label,
char *element_name, struct sbuf *sb, int *claimed);
@@ -738,7 +738,7 @@
mpo_cred_check_setresgid_t mpo_cred_check_setresgid;
mpo_cred_check_visible_t mpo_cred_check_visible;
mpo_cred_copy_label_t mpo_cred_copy_label;
- mpo_cred_create_swapper_t mpo_cred_create_swapper;
+ mpo_cred_create_kproc0_t mpo_cred_create_kproc0;
mpo_cred_create_init_t mpo_cred_create_init;
mpo_cred_destroy_label_t mpo_cred_destroy_label;
mpo_cred_externalize_label_t mpo_cred_externalize_label;
diff --git a/sys/security/mac_biba/mac_biba.c b/sys/security/mac_biba/mac_biba.c
--- a/sys/security/mac_biba/mac_biba.c
+++ b/sys/security/mac_biba/mac_biba.c
@@ -912,7 +912,7 @@
}
static void
-biba_cred_create_swapper(struct ucred *cred)
+biba_cred_create_kproc0(struct ucred *cred)
{
struct mac_biba *dest;
@@ -3574,7 +3574,7 @@
.mpo_cred_check_visible = biba_cred_check_visible,
.mpo_cred_copy_label = biba_copy_label,
.mpo_cred_create_init = biba_cred_create_init,
- .mpo_cred_create_swapper = biba_cred_create_swapper,
+ .mpo_cred_create_kproc0 = biba_cred_create_kproc0,
.mpo_cred_destroy_label = biba_destroy_label,
.mpo_cred_externalize_label = biba_externalize_label,
.mpo_cred_init_label = biba_init_label,
diff --git a/sys/security/mac_lomac/mac_lomac.c b/sys/security/mac_lomac/mac_lomac.c
--- a/sys/security/mac_lomac/mac_lomac.c
+++ b/sys/security/mac_lomac/mac_lomac.c
@@ -1008,7 +1008,7 @@
}
static void
-lomac_cred_create_swapper(struct ucred *cred)
+lomac_cred_create_kproc0(struct ucred *cred)
{
struct mac_lomac *dest;
@@ -2910,7 +2910,7 @@
.mpo_cred_check_relabel = lomac_cred_check_relabel,
.mpo_cred_check_visible = lomac_cred_check_visible,
.mpo_cred_copy_label = lomac_copy_label,
- .mpo_cred_create_swapper = lomac_cred_create_swapper,
+ .mpo_cred_create_kproc0 = lomac_cred_create_kproc0,
.mpo_cred_create_init = lomac_cred_create_init,
.mpo_cred_destroy_label = lomac_destroy_label,
.mpo_cred_externalize_label = lomac_externalize_label,
diff --git a/sys/security/mac_mls/mac_mls.c b/sys/security/mac_mls/mac_mls.c
--- a/sys/security/mac_mls/mac_mls.c
+++ b/sys/security/mac_mls/mac_mls.c
@@ -875,7 +875,7 @@
}
static void
-mls_cred_create_swapper(struct ucred *cred)
+mls_cred_create_kproc0(struct ucred *cred)
{
struct mac_mls *dest;
@@ -3203,7 +3203,7 @@
.mpo_cred_check_visible = mls_cred_check_visible,
.mpo_cred_copy_label = mls_copy_label,
.mpo_cred_create_init = mls_cred_create_init,
- .mpo_cred_create_swapper = mls_cred_create_swapper,
+ .mpo_cred_create_kproc0 = mls_cred_create_kproc0,
.mpo_cred_destroy_label = mls_destroy_label,
.mpo_cred_externalize_label = mls_externalize_label,
.mpo_cred_init_label = mls_init_label,
diff --git a/sys/security/mac_partition/mac_partition.c b/sys/security/mac_partition/mac_partition.c
--- a/sys/security/mac_partition/mac_partition.c
+++ b/sys/security/mac_partition/mac_partition.c
@@ -159,7 +159,7 @@
}
static void
-partition_cred_create_swapper(struct ucred *cred)
+partition_cred_create_kproc0(struct ucred *cred)
{
SLOT_SET(cred->cr_label, 0);
@@ -298,7 +298,7 @@
.mpo_cred_check_visible = partition_cred_check_visible,
.mpo_cred_copy_label = partition_cred_copy_label,
.mpo_cred_create_init = partition_cred_create_init,
- .mpo_cred_create_swapper = partition_cred_create_swapper,
+ .mpo_cred_create_kproc0 = partition_cred_create_kproc0,
.mpo_cred_destroy_label = partition_cred_destroy_label,
.mpo_cred_externalize_label = partition_cred_externalize_label,
.mpo_cred_init_label = partition_cred_init_label,
diff --git a/sys/security/mac_stub/mac_stub.c b/sys/security/mac_stub/mac_stub.c
--- a/sys/security/mac_stub/mac_stub.c
+++ b/sys/security/mac_stub/mac_stub.c
@@ -319,7 +319,7 @@
}
static void
-stub_cred_create_swapper(struct ucred *cred)
+stub_cred_create_kproc0(struct ucred *cred)
{
}
@@ -1720,7 +1720,7 @@
.mpo_cred_check_visible = stub_cred_check_visible,
.mpo_cred_copy_label = stub_copy_label,
.mpo_cred_create_init = stub_cred_create_init,
- .mpo_cred_create_swapper = stub_cred_create_swapper,
+ .mpo_cred_create_kproc0 = stub_cred_create_kproc0,
.mpo_cred_destroy_label = stub_destroy_label,
.mpo_cred_externalize_label = stub_externalize_label,
.mpo_cred_init_label = stub_init_label,
diff --git a/sys/security/mac_test/mac_test.c b/sys/security/mac_test/mac_test.c
--- a/sys/security/mac_test/mac_test.c
+++ b/sys/security/mac_test/mac_test.c
@@ -416,13 +416,13 @@
COUNTER_INC(cred_create_init);
}
-COUNTER_DECL(cred_create_swapper);
+COUNTER_DECL(cred_create_kproc0);
static void
-test_cred_create_swapper(struct ucred *cred)
+test_cred_create_kproc0(struct ucred *cred)
{
LABEL_CHECK(cred->cr_label, MAGIC_CRED);
- COUNTER_INC(cred_create_swapper);
+ COUNTER_INC(cred_create_kproc0);
}
COUNTER_DECL(cred_destroy_label);
@@ -3074,7 +3074,7 @@
.mpo_cred_check_visible = test_cred_check_visible,
.mpo_cred_copy_label = test_cred_copy_label,
.mpo_cred_create_init = test_cred_create_init,
- .mpo_cred_create_swapper = test_cred_create_swapper,
+ .mpo_cred_create_kproc0 = test_cred_create_kproc0,
.mpo_cred_destroy_label = test_cred_destroy_label,
.mpo_cred_externalize_label = test_cred_externalize_label,
.mpo_cred_init_label = test_cred_init_label,
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Mon, Jun 22, 7:06 PM (7 h, 6 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
34205730
Default Alt Text
D54052.diff (6 KB)
Attached To
Mode
D54052: MAC: Rename mac_cred_create_swapper to mac_cred_create_kproc0
Attached
Detach File
Event Timeline
Log In to Comment