secinfo
char *secinfo = NULL;
if (append_secattr(&secinfo, &len, aclp) == -1) {
write_ancillary(secinfo, len, B_TRUE);
char *secinfo = NULL;
if ((append_secattr(&secinfo, &len, aclp)) == -1)
write_ancillary(secinfo, len, B_TRUE);
char *secinfo = NULL;
if ((append_secattr(&secinfo, &len, aclp)) == -1)
write_ancillary(secinfo, len, B_TRUE);
append_secattr(char **secinfo, /* existing security info */
(void) memcpy(new_secinfo, *secinfo, oldsize);
free(*secinfo);
*secinfo = new_secinfo;
struct secinfo si;
addr = (uintptr_t)((struct secinfo *)addr + 1);
static void append_ext_attr(char *shortname, char **secinfo, int *len);
char **secinfo, /* existing security info */
(void) memcpy(new_secinfo, *secinfo, oldsize);
free(*secinfo);
*secinfo = new_secinfo;
write_ancillary(union hblock *dblockp, char *secinfo, int len, char hdrtype)
if (len == 0 || secinfo == NULL) {
(void) writetbuf((char *)secinfo, TBLOCKS(len));
char *secinfo = NULL;
(void) append_secattr(&secinfo, &len, acl_cnt(aclp),
append_ext_attr(shortname, &secinfo, &len);
(void) write_ancillary(&dblock, secinfo, len, ACL_HDR);
(void) write_ancillary(&dblock, secinfo, len, ACL_HDR);
append_ext_attr(char *shortname, char **secinfo, int *len)
(void) append_secattr(secinfo, len, 1,
(void) append_secattr(secinfo, len,
(void) append_secattr(secinfo, len,
struct secinfo *s = &export->ex_secinfo[i];
fill_security_from_secopts(struct secinfo *sp, sa_security_t secopts)
struct secinfo *sp;
struct secinfo *sp;
sp = calloc(num_secinfo, sizeof (struct secinfo));
seconfig_t secinfo;
(void) memset(&secinfo, '\0', sizeof (secinfo));
err = nfs_getseconfig_byname(mode, &secinfo);
smb_sd_read(char *path, smb_sd_t *sd, uint32_t secinfo)
smb_fssd_init(&fs_sd, secinfo, sd_flags);
smb_sd_write(char *path, smb_sd_t *sd, uint32_t secinfo)
smb_fssd_init(&fs_sd, secinfo, sd_flags);
smb_fssd_init(smb_fssd_t *fs_sd, uint32_t secinfo, uint32_t flags)
fs_sd->sd_secinfo = secinfo;
smb_sd_len(smb_sd_t *sd, uint32_t secinfo)
if (secinfo & SMB_OWNER_SECINFO)
if (secinfo & SMB_GROUP_SECINFO)
if (secinfo & SMB_DACL_SECINFO)
if (secinfo & SMB_SACL_SECINFO)
secinfo_free(sv_secinfo_t *secinfo)
if (secinfo == NULL)
for (i = 0; i < secinfo->count; i++) {
if (secinfo->sdata[i].rpcflavor == RPCSEC_GSS) {
secinfo->sdata[i].data;
(void) rpc_gss_secpurge((void *)&secinfo->sdata[i]);
if (secinfo->sdata[i].rpcflavor == AUTH_DH) {
secinfo->sdata[i].data = NULL;
kmem_free(secinfo->sdata, sizeof (sec_data_t) * secinfo->count);
kmem_free(secinfo, sizeof (sv_secinfo_t));
struct secinfo *secp;
struct secinfo *sp;
struct secinfo *sp;
struct secinfo *sp;
DTRACE_PROBE4(nfss__i__nmspc__secref, struct secinfo *, (seclist), \
struct secinfo *secp;
struct secinfo *sp;
struct secinfo *exs;
struct secinfo newsec[MAX_FLAVORS];
struct secinfo oldsec[MAX_FLAVORS];
allocsize = kex->ex_seccnt * SIZEOF_STRUCT(secinfo, model);
struct secinfo *sp2;
allocsize2 = kex->ex_seccnt * sizeof (struct secinfo);
STRUCT_HANDLE(secinfo, usi);
(struct secinfo *)((caddr_t)sp +
(i * SIZEOF_STRUCT(secinfo, model))));
srv_secinfo_entry_free(struct secinfo *secp)
kex->ex_seccnt * sizeof (struct secinfo));
srv_secinfo_list_free(struct secinfo *secinfo, int cnt)
struct secinfo cursec[MAX_FLAVORS];
srv_secinfo_entry_free(&secinfo[i]);
kmem_free(secinfo, cnt * sizeof (struct secinfo));
srv_secinfo_copy(struct secinfo *from, struct secinfo *to)
struct secinfo *sp;
struct secinfo *cursec;
struct secinfo *msec; /* merged secinfo list */
struct secinfo *cursec;
msec = kmem_zalloc(tcnt * sizeof (struct secinfo), KM_SLEEP);
kmem_free(cursec, ccnt * sizeof (struct secinfo));
struct secinfo *msec; /* final secinfo list after removing */
struct secinfo *cursec;
msec = kmem_zalloc(tcnt * sizeof (struct secinfo), KM_SLEEP);
kmem_free(*pcursec, ccnt * sizeof (struct secinfo));
struct secinfo *msec; /* merged secinfo list */
msec = kmem_zalloc(tcnt * sizeof (struct secinfo), KM_SLEEP);
kmem_free(curdata->ex_secinfo, ccnt * sizeof (struct secinfo));
struct secinfo *msec; /* merged secinfo list */
msec = kmem_zalloc(tcnt * sizeof (struct secinfo), KM_SLEEP);
struct secinfo *secp;
struct secinfo *sptr;
struct secinfo *secp;
struct secinfo *sptr;
uint32_t secinfo = SMB_DACL_SECINFO;
smb_fssd_init(&fs_sd, secinfo, sd_flags);
uint32_t secinfo = qi->qi_AddlInfo;
secinfo &= ~SMB_SACL_SECINFO;
status = smb_sd_read(sr, &sd, secinfo);
sdlen = smb_sd_len(&sd, secinfo);
smb_encode_sd(&sr->raw_data, &sd, secinfo);
smb2_setinfo_sec(smb_request_t *sr, smb_setinfo_t *si, uint32_t secinfo)
secinfo &= ~SMB_SACL_SECINFO;
if ((secinfo & SMB_ALL_SECINFO) == 0)
if (((secinfo & SMB_OWNER_SECINFO) && (sd.sd_owner == NULL)) ||
((secinfo & SMB_GROUP_SECINFO) && (sd.sd_group == NULL)))
status = smb_sd_write(sr, &sd, secinfo);
uint32_t secinfo;
secinfo = fs_sd->sd_secinfo;
if ((secinfo & SMB_ACL_SECINFO) == SMB_ACL_SECINFO)
if ((secinfo & SMB_DACL_SECINFO) == 0) {
if ((secinfo & SMB_SACL_SECINFO) == 0) {
uint32_t secinfo;
secinfo = smb_sd_get_secinfo(op->sd);
if ((secinfo & SMB_SACL_SECINFO) != 0 &&
smb_fssd_init(&fs_sd, secinfo, 0);
uint32_t secinfo;
secinfo = smb_sd_get_secinfo(op->sd);
if ((secinfo & SMB_SACL_SECINFO) != 0 &&
smb_fssd_init(&fs_sd, secinfo, SMB_FSSD_FLAGS_DIR);
sdlen = smb_sd_len(&sd, secinfo);
smb_encode_sd(&xa->rep_data_mb, &sd, secinfo);
uint32_t secinfo;
&sr->smb_fid, &secinfo) != 0) {
secinfo &= ~SMB_SACL_SECINFO;
if ((secinfo & SMB_ALL_SECINFO) == 0) {
if (((secinfo & SMB_OWNER_SECINFO) && (sd.sd_owner == NULL)) ||
((secinfo & SMB_GROUP_SECINFO) && (sd.sd_group == NULL))) {
status = smb_sd_write(sr, &sd, secinfo);
smb_encode_sd(mbuf_chain_t *mbc, smb_sd_t *sd, uint32_t secinfo)
if (secinfo & SMB_OWNER_SECINFO) {
if (secinfo & SMB_GROUP_SECINFO) {
if ((secinfo & SMB_SACL_SECINFO) && (sd->sd_sacl)) {
if ((secinfo & SMB_DACL_SECINFO) && (sd->sd_dacl))
if (secinfo & SMB_OWNER_SECINFO)
if (secinfo & SMB_GROUP_SECINFO)
if (secinfo & SMB_SACL_SECINFO)
if (secinfo & SMB_DACL_SECINFO)
uint32_t secinfo;
&sr->smb_fid, &secinfo) != 0) {
secinfo &= ~SMB_SACL_SECINFO;
status = smb_sd_read(sr, &sd, secinfo);
smb_sd_read(smb_request_t *sr, smb_sd_t *sd, uint32_t secinfo)
smb_fssd_init(&fs_sd, secinfo, sd_flags);
smb_sd_write(smb_request_t *sr, smb_sd_t *sd, uint32_t secinfo)
smb_fssd_init(&fs_sd, secinfo, sd_flags);
smb_fssd_init(smb_fssd_t *fs_sd, uint32_t secinfo, uint32_t flags)
fs_sd->sd_secinfo = secinfo;
smb_sd_len(smb_sd_t *sd, uint32_t secinfo)
if (secinfo & SMB_OWNER_SECINFO)
if (secinfo & SMB_GROUP_SECINFO)
if (secinfo & SMB_DACL_SECINFO)
if (secinfo & SMB_SACL_SECINFO)
struct secinfo *ex_secinfo; /* security mode info */
typedef struct secinfo secinfo_t;
struct secinfo *vis_secinfo;
extern void srv_secinfo_list_free(struct secinfo *, int);