Home
last modified time | relevance | path

Searched refs:sun_path (Results 1 – 25 of 37) sorted by relevance

12

/linux/tools/testing/selftests/net/af_unix/
H A Dunix_connect.c24 char sun_path[8]; in FIXTURE_VARIANT() local
33 .sun_path = "test", in FIXTURE_VARIANT_ADD()
42 .sun_path = "\0test", in FIXTURE_VARIANT_ADD()
51 .sun_path = "test", in FIXTURE_VARIANT_ADD()
60 .sun_path = "\0test", in FIXTURE_VARIANT_ADD()
69 .sun_path = "test", in FIXTURE_VARIANT_ADD()
78 .sun_path = "\0test", in FIXTURE_VARIANT_ADD()
87 .sun_path = "test", in FIXTURE_VARIANT_ADD()
96 .sun_path = "\0test", in FIXTURE_VARIANT_ADD()
112 if (variant->sun_path[0]) in FIXTURE_TEARDOWN()
[all …]
H A Dscm_pidfd.c278 char *sun_path_buf = (char *)&addr->listen_addr.sun_path; in fill_sockaddr()
281 addr->addrlen = offsetof(struct sockaddr_un, sun_path); in fill_sockaddr()
/linux/tools/testing/selftests/bpf/prog_tests/
H A Dbpf_iter_setsockopt_unix.c14 .sun_path = "", in create_unix_socket()
23 len = offsetof(struct sockaddr_un, sun_path); in create_unix_socket()
33 memcpy(&skel->bss->sun_path, &addr.sun_path, in create_unix_socket()
34 len - offsetof(struct sockaddr_un, sun_path)); in create_unix_socket()
H A Dskc_to_unix_sock.c37 strncpy(sockaddr.sun_path, sock_path, strlen(sock_path)); in test_skc_to_unix_sock()
38 sockaddr.sun_path[0] = '\0'; in test_skc_to_unix_sock()
/linux/tools/testing/selftests/bpf/progs/
H A Dbpf_iter_setsockopt_unix.c9 char sun_path[AUTOBIND_LEN]; variable
21 if (unix_sk->addr->name->sun_path[i] != sun_path[i]) in cmpname()
37 if (unix_sk->addr->name->sun_path[0]) in change_sndbuf()
H A Dbpf_iter_unix.c52 if (unix_sk->addr->name->sun_path[0]) { in dump_unix()
53 BPF_SEQ_PRINTF(seq, " %s", unix_sk->addr->name->sun_path); in dump_unix()
71 unix_sk->addr->name->sun_path[i] ?: in dump_unix()
H A Drecvmsg_unix_prog.c18 __u32 unaddrlen = offsetof(struct sockaddr_un, sun_path) + in recvmsg_unix_prog()
31 if (memcmp(sa_kern_unaddr->sun_path, SERVUN_ADDRESS, in recvmsg_unix_prog()
H A Dgetsockname_unix_prog.c18 __u32 unaddrlen = offsetof(struct sockaddr_un, sun_path) + in getsockname_unix_prog()
31 if (memcmp(sa_kern_unaddr->sun_path, SERVUN_REWRITE_ADDRESS, in getsockname_unix_prog()
H A Dgetpeername_unix_prog.c18 __u32 unaddrlen = offsetof(struct sockaddr_un, sun_path) + in getpeername_unix_prog()
31 if (memcmp(sa_kern_unaddr->sun_path, SERVUN_REWRITE_ADDRESS, in getpeername_unix_prog()
H A Dconnect_unix_prog.c18 __u32 unaddrlen = offsetof(struct sockaddr_un, sun_path) + in connect_unix_prog()
32 if (memcmp(sa_kern_unaddr->sun_path, SERVUN_REWRITE_ADDRESS, in connect_unix_prog()
H A Dsendmsg_unix_prog.c18 __u32 unaddrlen = offsetof(struct sockaddr_un, sun_path) + in sendmsg_unix_prog()
32 if (memcmp(sa_kern_unaddr->sun_path, SERVUN_REWRITE_ADDRESS, in sendmsg_unix_prog()
H A Dtest_skc_to_unix_sock.c26 if (unix_sk->addr->name->sun_path[0]) in BPF_PROG()
35 path[i] = unix_sk->addr->name->sun_path[i]; in BPF_PROG()
/linux/tools/testing/selftests/landlock/
H A Dscoped_abstract_unix_test.c688 snprintf(stream_pathname_addr.sun_path, in TEST_F()
689 sizeof(stream_pathname_addr.sun_path), "%s", stream_path); in TEST_F()
690 size_stream = offsetof(struct sockaddr_un, sun_path) + in TEST_F()
691 strlen(stream_pathname_addr.sun_path); in TEST_F()
692 snprintf(dgram_pathname_addr.sun_path, in TEST_F()
693 sizeof(dgram_pathname_addr.sun_path), "%s", dgram_path); in TEST_F()
694 size_dgram = offsetof(struct sockaddr_un, sun_path) + in TEST_F()
695 strlen(dgram_pathname_addr.sun_path); in TEST_F()
H A Dcommon.h262 sprintf(srv->unix_addr.sun_path, in set_unix_address()
266 srv->unix_addr.sun_path[0] = '\0'; in set_unix_address()
/linux/security/landlock/
H A Dtask.c200 if (addr->len >= offsetof(struct sockaddr_un, sun_path) + 1 && in is_abstract_socket()
201 addr->name->sun_path[0] == '\0') in is_abstract_socket()
/linux/include/uapi/linux/
H A Dun.h11 char sun_path[UNIX_PATH_MAX]; /* pathname */ member
/linux/tools/perf/
H A Dbuiltin-daemon.c601 if (strlen(path) + 1 >= sizeof(addr.sun_path)) { in setup_server_socket()
610 strlcpy(addr.sun_path, path, sizeof(addr.sun_path) - 1); in setup_server_socket()
873 if (strlen(path) + 1 >= sizeof(addr.sun_path)) { in setup_client_socket()
881 strlcpy(addr.sun_path, path, sizeof(addr.sun_path) - 1); in setup_client_socket()
/linux/arch/um/os-Linux/
H A Dfile.c222 snprintf(sock.sun_path, sizeof(sock.sun_path), "%s", name); in os_connect_socket()
575 snprintf(addr.sun_path, len, "%s", file); in os_create_unix_socket()
/linux/net/unix/
H A Ddiag.c23 addr->len - offsetof(struct sockaddr_un, sun_path), in sk_diag_dump_name()
24 addr->name->sun_path); in sk_diag_dump_name()
H A Daf_unix.c348 if (addr_len <= offsetof(struct sockaddr_un, sun_path) || in unix_validate_addr()
363 BUILD_BUG_ON(offset != offsetof(struct sockaddr_un, sun_path)); in unix_mkname_bsd()
1124 err = kern_path(sunaddr->sun_path, LOOKUP_FOLLOW, &path); in unix_find_bsd()
1184 if (sunaddr->sun_path[0]) in unix_find_other()
1210 offsetof(struct sockaddr_un, sun_path) + 16, GFP_KERNEL); in unix_autobind()
1214 addr->len = offsetof(struct sockaddr_un, sun_path) + 6; in unix_autobind()
1223 sprintf(addr->name->sun_path + 1, "%05x", ordernum); in unix_autobind()
1277 dentry = kern_path_create(AT_FDCWD, addr->name->sun_path, &parent, 0); in unix_bind_bsd()
1373 if (addr_len == offsetof(struct sockaddr_un, sun_path) && in unix_bind()
1381 if (sunaddr->sun_path[0]) in unix_bind()
[all …]
/linux/tools/testing/selftests/bpf/
H A Dbpf_kfuncs.h52 const __u8 *sun_path, __u32 sun_path__sz) __ksym;
/linux/net/sunrpc/
H A Drpcb_clnt.c221 # define SUN_LEN(ptr) (offsetof(struct sockaddr_un, sun_path) \
222 + 1 + strlen((ptr)->sun_path + 1))
278 .sun_path = RPCBIND_SOCK_ABSTRACT_NAME, in rpcb_create_local_abstract()
288 .sun_path = RPCBIND_SOCK_PATHNAME, in rpcb_create_local_unix()
/linux/tools/perf/trace/beauty/
H A Dsockaddr.c39 return scnprintf(bf, size, ", path: %s", sun->sun_path); in af_local__scnprintf()
/linux/arch/um/drivers/
H A Ddaemon_user.c44 memcpy(sun->sun_path, name, len); in new_addr()
H A Dvector_user.c341 memcpy(local_addr->sun_path, src, strlen(src) + 1); in user_init_unix_fds()
346 memcpy(remote_addr->sun_path, dst, strlen(dst) + 1); in user_init_unix_fds()
370 printk(UM_KERN_ERR "bess open:cannot connect to %s %i", remote_addr->sun_path, -errno); in user_init_unix_fds()

12