/freebsd/tools/regression/priv/ |
H A D | priv_vfs_chflags.c | 48 static char fpath[1024]; variable 71 setup_file("priv_vfs_chflags_froot_setup: fpath", fpath, UID_ROOT, in priv_vfs_chflags_froot_setup() 82 setup_file("priv_vfs_chflags_fowner_setup: fpath", fpath, UID_OWNER, in priv_vfs_chflags_fowner_setup() 93 setup_file("priv_vfs_chflags_fowner_setup: fpath", fpath, UID_OTHER, in priv_vfs_chflags_fother_setup() 106 flags = getflags(fpath); in priv_vfs_chflags_froot_uflags() 108 error = chflags(fpath, flags); in priv_vfs_chflags_froot_uflags() 130 flags = getflags(fpath); in priv_vfs_chflags_fowner_uflags() 132 error = chflags(fpath, flags); in priv_vfs_chflags_fowner_uflags() 154 flags = getflags(fpath); in priv_vfs_chflags_fother_uflags() 156 error = chflags(fpath, flags); in priv_vfs_chflags_fother_uflags() [all …]
|
H A D | priv_vfs_utimes.c | 48 static char fpath[1024]; variable 55 setup_file("priv_vfs_utimes_froot_setup: fpath", fpath, in priv_vfs_utimes_froot_setup() 65 setup_file("priv_vfs_utimes_fowner_setup: fpath", fpath, in priv_vfs_utimes_fowner_setup() 81 setup_file("priv_vfs_utimes_fother_setup: fpath", fpath, in priv_vfs_utimes_fother_setup() 97 error = utimes(fpath, tv); in priv_vfs_utimes_froot() 115 error = utimes(fpath, NULL); in priv_vfs_utimes_froot_null() 140 error = utimes(fpath, tv); in priv_vfs_utimes_fowner() 156 error = utimes(fpath, NULL); in priv_vfs_utimes_fowner_null() 181 error = utimes(fpath, tv); in priv_vfs_utimes_fother() 199 error = utimes(fpath, NULL); in priv_vfs_utimes_fother_null() [all …]
|
H A D | priv_vfs_clearsugid.c | 62 static char fpath[1024]; variable 74 if (stat(fpath, &sb) < 0) { in confirm_sugid() 75 warn("%s stat(%s)", test_case, fpath); in confirm_sugid() 93 setup_file("priv_vfs_clearsugid_setup: fpath", fpath, UID_OWNER, in priv_vfs_clearsugid_setup() 103 if (chown(fpath, -1, asroot ? GID_WHEEL : GID_OWNER) < 0) in priv_vfs_clearsugid_chgrp() 118 if (extattr_set_file(fpath, EA_NAMESPACE, EA_NAME, EA_DATA, EA_SIZE) in priv_vfs_clearsugid_extattr() 131 fd = open(fpath, O_RDWR); in priv_vfs_clearsugid_write() 147 (void)unlink(fpath); in priv_vfs_clearsugid_cleanup()
|
H A D | priv_vfs_chmod.c | 47 static char fpath[1024]; variable 54 setup_file("priv_vfs_chmod_setup: fpath", fpath, UID_ROOT, GID_WHEEL, in priv_vfs_chmod_froot_setup() 64 setup_file("priv_vfs_chmod_setup: fpath", fpath, UID_OWNER, in priv_vfs_chmod_fowner_setup() 74 setup_file("priv_vfs_chmod_setup: fpath", fpath, UID_OTHER, in priv_vfs_chmod_fother_setup() 85 error = chmod(fpath, 0640); in priv_vfs_chmod_froot() 103 error = chmod(fpath, 0640); in priv_vfs_chmod_fowner() 122 error = chmod(fpath, 0640); in priv_vfs_chmod_fother() 141 (void)unlink(fpath); in priv_vfs_chmod_cleanup()
|
H A D | priv_vfs_generation.c | 48 static char fpath[1024]; variable 66 setup_file("priv_vfs_generation_setup: fpath", fpath, in priv_vfs_generation_setup() 68 if (stat(fpath, &sb) < 0) { in priv_vfs_generation_setup() 69 warn("priv_vfs_generation_setup: fstat(%s)", fpath); in priv_vfs_generation_setup() 70 (void)unlink(fpath); in priv_vfs_generation_setup() 88 error = stat(fpath, &sb); in priv_vfs_generation() 115 (void)unlink(fpath); in priv_vfs_generation_cleanup()
|
H A D | priv_vfs_chown.c | 52 static char fpath[1024]; variable 62 setup_file("priv_vfs_chown_uid: fpath", fpath, UID_ROOT, GID_WHEEL, in priv_vfs_chown_uid_setup() 73 error = chown(fpath, UID_OWNER, -1); in priv_vfs_chown_uid() 96 setup_file("priv_vfs_chown_mygid: fpath", fpath, asroot ? UID_ROOT : in priv_vfs_chown_mygid_setup() 107 error = chown(fpath, -1, asroot ? GID_WHEEL : GID_OWNER); in priv_vfs_chown_mygid() 130 setup_file("priv_vfs_chown_othergid: fpath", fpath, asroot ? UID_ROOT in priv_vfs_chown_othergid_setup() 141 error = chown(fpath, -1, GID_OTHER); in priv_vfs_chown_othergid() 159 (void)unlink(fpath); in priv_vfs_chown_cleanup()
|
H A D | priv_vfs_setgid.c | 47 static char fpath[1024]; variable 54 setup_file("priv_vfs_setgid_fowner: fpath", fpath, UID_OWNER, in priv_vfs_setgid_fowner_setup() 65 setup_file("priv_vfs_setgid_forther: fpath", fpath, UID_OWNER, in priv_vfs_setgid_fother_setup() 76 error = chmod(fpath, 0600 | S_ISGID); in priv_vfs_setgid_fowner() 96 error = chmod(fpath, 0600 | S_ISGID); in priv_vfs_setgid_fother() 116 (void)unlink(fpath); in priv_vfs_setgid_cleanup()
|
H A D | priv_vfs_fhstat.c | 46 static char fpath[1024]; variable 54 setup_file("priv_vfs_fhstat_setup: fpath", fpath, UID_ROOT, in priv_vfs_fhstat_setup() 57 if (getfh(fpath, &fh) < 0) { in priv_vfs_fhstat_setup() 58 warn("priv_vfs_fhstat_setup: getfh(%s)", fpath); in priv_vfs_fhstat_setup() 86 (void)unlink(fpath); in priv_vfs_fhstat_cleanup()
|
H A D | priv_vfs_fhstatfs.c | 45 static char fpath[1024]; variable 53 setup_file("priv_vfs_fhstatfs_setup: fpath", fpath, UID_ROOT, in priv_vfs_fhstatfs_setup() 56 if (getfh(fpath, &fh) < 0) { in priv_vfs_fhstatfs_setup() 57 warn("priv_vfs_fhstatfs_setup: getfh(%s)", fpath); in priv_vfs_fhstatfs_setup() 88 (void)unlink(fpath); in priv_vfs_fhstatfs_cleanup()
|
H A D | priv_vfs_fhopen.c | 46 static char fpath[1024]; variable 54 setup_file("private_vfs_fhopen_setup: fpath", fpath, UID_ROOT, in priv_vfs_fhopen_setup() 57 if (getfh(fpath, &fh) < 0) { in priv_vfs_fhopen_setup() 58 warn("priv_vfs_fhopen_setup: getfh(%s)", fpath); in priv_vfs_fhopen_setup() 92 (void)unlink(fpath); in priv_vfs_fhopen_cleanup()
|
H A D | priv_vfs_stickyfile.c | 44 char fpath[1024]; variable 77 setup_file("priv_vfs_stickyfile_fowner_setup: fpath", fpath, in priv_vfs_stickyfile_file_fowner_setup() 88 setup_file("priv_vfs_stickyfile_fother_setup: fpath", fpath, in priv_vfs_stickyfile_file_fother_setup() 139 error = chmod(fpath, 0600 | S_ISTXT); in priv_vfs_stickyfile_file_fowner() 159 error = chmod(fpath, 0600 | S_ISTXT); in priv_vfs_stickyfile_file_fother() 189 (void)unlink(fpath); in priv_vfs_stickyfile_file_cleanup()
|
H A D | priv_vfs_getfh.c | 44 static char fpath[1024]; variable 50 setup_file("priv_vfs_getfh_setup: fpath", fpath, UID_ROOT, GID_WHEEL, in priv_vfs_getfh_setup() 61 error = getfh(fpath, &fh); in priv_vfs_getfh() 76 (void)unlink(fpath); in priv_vfs_getfh_cleanup()
|
H A D | priv_vfs_extattr_system.c | 51 static char fpath[1024]; variable 62 setup_file("priv_vfs_extattr_system_setup: fpath", fpath, UID_ROOT, in priv_vfs_extattr_system_setup() 74 ret = extattr_set_file(fpath, EA_NAMESPACE, EA_NAME, EA_DATA, in priv_vfs_extattr_system() 101 (void)unlink(fpath); in priv_vfs_extattr_system_cleanup()
|
/freebsd/sys/contrib/openzfs/tests/zfs-tests/cmd/ |
H A D | suid_write_to_file.c | 72 char fpath[1024]; in main() local 73 snprintf(fpath, sizeof (fpath), "%s/%s", testdir, name); in main() 80 unlink(fpath); in main() 81 if (stat(fpath, &st) == 0) { in main() 82 fprintf(stderr, "%s exists\n", fpath); in main() 88 fd = creat(fpath, 0777 | extra); in main() 100 fd = open(fpath, O_RDWR); in main() 120 if (stat(fpath, &st) == -1) { in main()
|
H A D | mkbusy.c | 87 char *fpath = NULL; in main() local 131 if (asprintf(&fpath, "%s/%s", dname, fname) == -1) in main() 143 if ((fpath = strdup(argv[0])) == NULL) in main() 151 if (open(fpath, O_CREAT | O_RDWR, 0600) < 0) in main() 154 if (opendir(fpath) == NULL) in main() 157 free(fpath); in main()
|
/freebsd/contrib/netbsd-tests/fs/vfs/ |
H A D | t_vfsops.c | 77 char fpath[MAXPATHLEN]; in tfilehandle() local 83 sprintf(fpath, "%s/file", path); in tfilehandle() 84 fd = rump_sys_open(fpath, O_RDWR | O_CREAT, 0777); in tfilehandle() 97 if (rump_sys_getfh(fpath, NULL, &fhsize) == -1) { in tfilehandle() 106 if (rump_sys_getfh(fpath, fhp, &fhsize) == -1) in tfilehandle()
|
/freebsd/lib/libpmc/pmu-events/ |
H A D | jevents.c | 886 static int process_mapfile(FILE *outfp, char *fpath) in process_mapfile() argument 896 pr_info("%s: Processing mapfile %s\n", prog, fpath); in process_mapfile() 902 mapfp = fopen(fpath, "r"); in process_mapfile() 905 fpath); in process_mapfile() 932 prog, fpath, line_num); in process_mapfile() 1016 static int is_leaf_dir(const char *fpath) in is_leaf_dir() argument 1022 d = opendir(fpath); in is_leaf_dir() 1037 snprintf(path, sizeof(path), "%s/%s", fpath, dir->d_name); in is_leaf_dir() 1067 static int preprocess_arch_std_files(const char *fpath, const struct stat *sb, in preprocess_arch_std_files() argument 1073 if (level == 1 && is_file && is_json_file(fpath)) in preprocess_arch_std_files() 1079 process_one_file(const char * fpath,const struct stat * sb,int typeflag,struct FTW * ftwbuf) process_one_file() argument [all...] |
/freebsd/cddl/usr.sbin/dwatch/libexec/ |
H A D | vop_rename | 211 this->fpath = this->ffi_mount; 212 this->fpath = strjoin(this->fpath, this->ffi_mount != 0 ? ( 229 this->fpath = strjoin(this->fpath, 235 this->fpath = strjoin(this->fpath, strjoin(this->fname = 240 this->fpath = strjoin(this->fpath, 294 printf("%s -> %s", this->fpath, this->tpath);
|
/freebsd/tools/tools/kdrv/ |
H A D | KernelDriver | 585 if {[scan $line "\# filei386: %s" fpath] == 1} { 586 set f [file tail $fpath]; 587 set Drv(filei386:$f) "[file dirname $fpath]/"; 624 if {[scan $line "\# fileconf: %s" fpath] == 1} { 625 set f [file tail $fpath]; 626 set Drv(fileconf:$f) "[file dirname $fpath]/"; 697 if {[scan $line "\# file: %s" fpath] == 1} { 698 set f [file tail $fpath]; 699 set Drv(filei386:$f) "[file dirname $fpath]/"; 737 if {[scan $line "\# file: %s" fpath] == 1} { [all …]
|
/freebsd/crypto/openssl/crypto/ct/ |
H A D | ct_log.c | 170 const char *fpath = ossl_safe_getenv(CTLOG_FILE_EVP); in CTLOG_STORE_load_default_file() local 172 if (fpath == NULL) in CTLOG_STORE_load_default_file() 173 fpath = CTLOG_FILE; in CTLOG_STORE_load_default_file() 175 return CTLOG_STORE_load_file(store, fpath); in CTLOG_STORE_load_default_file()
|
/freebsd/usr.sbin/boot0cfg/ |
H A D | boot0cfg.c | 120 const char *bpath, *fpath; in main() local 128 fpath = NULL; in main() 154 fpath = optarg; in main() 199 if (fpath) in main() 200 write_mbr(fpath, O_CREAT | O_TRUNC, mbr, mbr_size, 0); in main()
|
/freebsd/usr.sbin/config/ |
H A D | mkoptions.cc | 292 char *fpath; in tooption() local 304 fpath = path(nbuf); in tooption() 305 (void)strlcpy(hbuf, fpath, sizeof(hbuf)); in tooption() 306 free(fpath); in tooption()
|