aboutsummaryrefslogtreecommitdiff
path: root/sys
diff options
context:
space:
mode:
authorMateusz Guzik <mjg@FreeBSD.org>2020-09-01 21:26:00 +0000
committerMateusz Guzik <mjg@FreeBSD.org>2020-09-01 21:26:00 +0000
commite5ecee7440496904939e936501d0db93bed15415 (patch)
tree454d5fe169c8881519befda38dffc2c0fbfd3b39 /sys
parent7c8e2a57ddc4c00add6ba2468d9cdf85b77b4d5b (diff)
Notes
Diffstat (limited to 'sys')
-rw-r--r--sys/security/audit/audit_bsm.c1
-rw-r--r--sys/security/audit/audit_dtrace.c2
-rw-r--r--sys/security/audit/audit_syscalls.c1
-rw-r--r--sys/security/audit/bsm_token.c2
-rw-r--r--sys/security/mac/mac_internal.h1
-rw-r--r--sys/security/mac/mac_label.c1
-rw-r--r--sys/security/mac/mac_socket.c2
-rw-r--r--sys/security/mac_biba/mac_biba.c2
-rw-r--r--sys/security/mac_lomac/mac_lomac.c2
-rw-r--r--sys/security/mac_mls/mac_mls.c3
-rw-r--r--sys/security/mac_stub/mac_stub.c7
-rw-r--r--sys/security/mac_veriexec/veriexec_metadata.c1
-rw-r--r--sys/security/mac_veriexec_parser/mac_veriexec_parser.c1
13 files changed, 4 insertions, 22 deletions
diff --git a/sys/security/audit/audit_bsm.c b/sys/security/audit/audit_bsm.c
index 3094509dbfdd..6742470c9578 100644
--- a/sys/security/audit/audit_bsm.c
+++ b/sys/security/audit/audit_bsm.c
@@ -318,7 +318,6 @@ kau_free(struct au_record *rec)
} \
} while (0)
-
/*
* Implement auditing for the auditon() system call. The audit tokens that
* are generated depend on the command that was sent into the auditon()
diff --git a/sys/security/audit/audit_dtrace.c b/sys/security/audit/audit_dtrace.c
index 985baf142ab3..21a290217288 100644
--- a/sys/security/audit/audit_dtrace.c
+++ b/sys/security/audit/audit_dtrace.c
@@ -383,7 +383,6 @@ dtaudit_au_evnamemap_callback(struct evname_elem *ene)
if ((ene->ene_commit_probe_id == 0) &&
(dtrace_probe_lookup(dtaudit_id, dtaudit_module_str,
ene_name_lower, dtaudit_name_commit_str) == 0)) {
-
/*
* Create the commit probe.
*
@@ -413,7 +412,6 @@ dtaudit_au_evnamemap_callback(struct evname_elem *ene)
if ((ene->ene_bsm_probe_id == 0) &&
(dtrace_probe_lookup(dtaudit_id, dtaudit_module_str,
ene_name_lower, dtaudit_name_bsm_str) == 0)) {
-
/*
* Create the bsm probe.
*
diff --git a/sys/security/audit/audit_syscalls.c b/sys/security/audit/audit_syscalls.c
index 8548c4e1f74b..5f07241109f1 100644
--- a/sys/security/audit/audit_syscalls.c
+++ b/sys/security/audit/audit_syscalls.c
@@ -90,7 +90,6 @@ sys_audit(struct thread *td, struct audit_args *uap)
* commit the user audit record.
*/
if (ar == NULL) {
-
/*
* This is not very efficient; we're required to allocate a
* complete kernel audit record just so the user record can
diff --git a/sys/security/audit/bsm_token.c b/sys/security/audit/bsm_token.c
index 05a1dcff93f7..2dc4df2aa1b8 100644
--- a/sys/security/audit/bsm_token.c
+++ b/sys/security/audit/bsm_token.c
@@ -52,7 +52,6 @@ __FBSDID("$FreeBSD$");
#include <netinet/in_systm.h>
#include <netinet/ip.h>
-
#include <bsm/audit.h>
#include <bsm/audit_internal.h>
#include <bsm/audit_record.h>
@@ -342,7 +341,6 @@ au_to_data(char unit_print, char unit_type, char unit_count, const char *p)
return (t);
}
-
/*
* token ID 1 byte
* status 4 bytes
diff --git a/sys/security/mac/mac_internal.h b/sys/security/mac/mac_internal.h
index 52d4a681486a..c5437f78b029 100644
--- a/sys/security/mac/mac_internal.h
+++ b/sys/security/mac/mac_internal.h
@@ -160,7 +160,6 @@ struct label {
intptr_t l_perpolicy[MAC_MAX_SLOTS];
};
-
/*
* Flags for mac_labeled, a bitmask of object types need across the union of
* all policies currently registered with the MAC Framework, used to key
diff --git a/sys/security/mac/mac_label.c b/sys/security/mac/mac_label.c
index c05865316373..86796f25cd04 100644
--- a/sys/security/mac/mac_label.c
+++ b/sys/security/mac/mac_label.c
@@ -93,7 +93,6 @@ mac_destroy_label(struct label *label)
#endif
}
-
static int
mac_labelzone_ctor(void *mem, int size, void *arg, int flags)
{
diff --git a/sys/security/mac/mac_socket.c b/sys/security/mac/mac_socket.c
index 95cfc6b06023..d55487897522 100644
--- a/sys/security/mac/mac_socket.c
+++ b/sys/security/mac/mac_socket.c
@@ -275,7 +275,7 @@ mac_socketpeer_set_from_mbuf(struct mbuf *m, struct socket *so)
void
mac_socketpeer_set_from_socket(struct socket *oldso, struct socket *newso)
{
-
+
if (mac_policy_count == 0)
return;
diff --git a/sys/security/mac_biba/mac_biba.c b/sys/security/mac_biba/mac_biba.c
index 84e38fcc5218..296d4a4e25b8 100644
--- a/sys/security/mac_biba/mac_biba.c
+++ b/sys/security/mac_biba/mac_biba.c
@@ -2745,7 +2745,7 @@ biba_sysvshm_check_shmat(struct ucred *cred, struct shmid_kernel *shmsegptr,
if (!biba_dominate_effective(subj, obj))
return (EACCES);
}
-
+
return (0);
}
diff --git a/sys/security/mac_lomac/mac_lomac.c b/sys/security/mac_lomac/mac_lomac.c
index dca68b4877d8..821b0faf68d0 100644
--- a/sys/security/mac_lomac/mac_lomac.c
+++ b/sys/security/mac_lomac/mac_lomac.c
@@ -731,7 +731,7 @@ lomac_parse_element(struct mac_lomac_element *element, char *string)
p0 = string;
d = strtol(p0, &p1, 10);
-
+
if (d < 0 || d > 65535)
return (EINVAL);
element->mle_type = MAC_LOMAC_TYPE_GRADE;
diff --git a/sys/security/mac_mls/mac_mls.c b/sys/security/mac_mls/mac_mls.c
index a0e71403b802..da9ed8a3e141 100644
--- a/sys/security/mac_mls/mac_mls.c
+++ b/sys/security/mac_mls/mac_mls.c
@@ -2378,7 +2378,7 @@ mls_sysvshm_check_shmat(struct ucred *cred, struct shmid_kernel *shmsegptr,
if (!mls_dominate_effective(obj, subj))
return (EACCES);
}
-
+
return (0);
}
@@ -3372,7 +3372,6 @@ static struct mac_policy_ops mls_ops =
.mpo_sysvshm_destroy_label = mls_destroy_label,
.mpo_sysvshm_init_label = mls_init_label,
-
.mpo_system_check_acct = mls_system_check_acct,
.mpo_system_check_auditctl = mls_system_check_auditctl,
.mpo_system_check_swapon = mls_system_check_swapon,
diff --git a/sys/security/mac_stub/mac_stub.c b/sys/security/mac_stub/mac_stub.c
index 6ee3c34dcc94..8174345f073a 100644
--- a/sys/security/mac_stub/mac_stub.c
+++ b/sys/security/mac_stub/mac_stub.c
@@ -1181,7 +1181,6 @@ stub_sysvmsq_check_msgrcv(struct ucred *cred, struct msg *msgptr,
return (0);
}
-
static int
stub_sysvmsq_check_msgrmid(struct ucred *cred, struct msg *msgptr,
struct label *msglabel)
@@ -1190,7 +1189,6 @@ stub_sysvmsq_check_msgrmid(struct ucred *cred, struct msg *msgptr,
return (0);
}
-
static int
stub_sysvmsq_check_msqget(struct ucred *cred, struct msqid_kernel *msqkptr,
struct label *msqklabel)
@@ -1199,7 +1197,6 @@ stub_sysvmsq_check_msqget(struct ucred *cred, struct msqid_kernel *msqkptr,
return (0);
}
-
static int
stub_sysvmsq_check_msqsnd(struct ucred *cred, struct msqid_kernel *msqkptr,
struct label *msqklabel)
@@ -1216,7 +1213,6 @@ stub_sysvmsq_check_msqrcv(struct ucred *cred, struct msqid_kernel *msqkptr,
return (0);
}
-
static int
stub_sysvmsq_check_msqctl(struct ucred *cred, struct msqid_kernel *msqkptr,
struct label *msqklabel, int cmd)
@@ -1225,7 +1221,6 @@ stub_sysvmsq_check_msqctl(struct ucred *cred, struct msqid_kernel *msqkptr,
return (0);
}
-
static void
stub_sysvmsq_cleanup(struct label *msqlabel)
{
@@ -1255,7 +1250,6 @@ stub_sysvsem_check_semget(struct ucred *cred, struct semid_kernel *semakptr,
return (0);
}
-
static int
stub_sysvsem_check_semop(struct ucred *cred, struct semid_kernel *semakptr,
struct label *semaklabel, size_t accesstype)
@@ -1301,7 +1295,6 @@ stub_sysvshm_check_shmdt(struct ucred *cred, struct shmid_kernel *shmsegptr,
return (0);
}
-
static int
stub_sysvshm_check_shmget(struct ucred *cred, struct shmid_kernel *shmsegptr,
struct label *shmseglabel, int shmflg)
diff --git a/sys/security/mac_veriexec/veriexec_metadata.c b/sys/security/mac_veriexec/veriexec_metadata.c
index 8961835b84dc..0a8505f5d951 100644
--- a/sys/security/mac_veriexec/veriexec_metadata.c
+++ b/sys/security/mac_veriexec/veriexec_metadata.c
@@ -773,7 +773,6 @@ mac_veriexec_metadata_get_file_info(dev_t fsid, long fileid, unsigned long gen,
return (ip);
}
-
/**
* @brief Intialize the meta-data store
*/
diff --git a/sys/security/mac_veriexec_parser/mac_veriexec_parser.c b/sys/security/mac_veriexec_parser/mac_veriexec_parser.c
index dc3b1301f9ee..41f70bb7074a 100644
--- a/sys/security/mac_veriexec_parser/mac_veriexec_parser.c
+++ b/sys/security/mac_veriexec_parser/mac_veriexec_parser.c
@@ -233,7 +233,6 @@ verify_digest(const char *data, size_t len, const unsigned char *expected_hash)
return (memcmp(expected_hash, hash, SHA256_DIGEST_LENGTH));
}
-
static int
open_file(const char *path, struct nameidata *nid)
{