Hi Bell and Thomas, Thanks for your support. I tried this as per your suggestions. Now I am able to run this successfully.
Can you also help me is there any documentatin and sample demo examples using APIs of libsec(3SEC) ,libsecdb(3SEC),libbsm(3BSM),libcontrat(3CONTRACT). Thanks and Regards Bhushan First I should mention that the security-discuss is probably a better alias for this sort of question. Nonetheless, I can see one problem in the code below. aclp should be declared as acl_t *aclp; /* just one star */ tom -----Original Message----- From: Tim.Bell at Sun.COM [mailto:tim.b...@sun.com] Sent: Friday, January 18, 2008 1:54 AM To: verma Cc: smf-discuss at opensolaris.org Subject: Re: [smf-discuss] Regarding libsec(3SEC) libraries call Hi Try this version: #include <stdio.h> #include <errno.h> #include <sys/acl.h> int main() { int convert; char *acltextp = "user:bhushan:rw_"; acl_t *aclp; errno = 0; convert = acl_fromtext(acltextp, &aclp); if (errno != 0) { perror("acl_fromtext error: "); } if (convert == 0) printf("converted\n"); else printf("error: %d\n", convert); return 0; } When run on my system, I get: error: 11 Looking in /usr/include/sys/acl.h I see: #define EACL_PERM_MASK_ERROR 11 /* unknown permission */ Hope this helps- Tim