search for: cap_t

Displaying 5 results from an estimated 5 matches for "cap_t".

2004 Jan 26
1
patch for linux capabilities
...nclude <sys/capability.h> +#define _POSIX_SOURCE +#else +#include <sys/prctl.h> +#include <sys/capability.h> +#endif +#endif + #include "rsync.h" extern int module_id; @@ -217,6 +229,10 @@ int start_glob=0; int ret; char *request=NULL; +#ifdef HAVE_LINUX_CAPS + cap_t cp; + cap_value_t newcaps[2] = { CAP_SYS_CHROOT, CAP_DAC_READ_SEARCH }; +#endif extern int am_sender; extern int am_server; extern int am_daemon; @@ -373,12 +389,46 @@ } #endif +#ifdef HAVE_LINUX_CAPS + if (setreuid(uid, 0)) { + rsyserr(FERROR, errno, "setreuid(%d,0) failed&quot...
2007 Feb 23
0
Simple patch
...clude <sys/wait.h> +#ifdef HAVE_LIBCAP +#include <sys/capability.h> +#endif const char *process_names[PROCESS_TYPE_MAX] = { "unknown", @@ -36,6 +39,15 @@ "dict" }; +/* the capabilities that we *need* in order to operate */ +#ifdef HAVE_LIBCAP +cap_t caps; +cap_value_t suidcaps[] = { + CAP_SETUID, + CAP_NET_BIND_SERVICE +}; +#endif + static const char *configfile = SYSCONFDIR "/" PACKAGE ".conf"; static const char *env_tz; @@ -583,6 +595,18 @@ if (log_error) i_fatal("This is Do...
2005 May 12
0
[PATCH] Trusted IRIX Support
...TH_IRIX_MAC */ void irix_setusercontext(struct passwd *pw) *************** *** 84,86 **** --- 92,144 ---- #endif /* defined(WITH_IRIX_PROJECT) || defined(WITH_IRIX_JOBS) || defined(WITH_IRIX_ARRAY) */ + + #ifdef WITH_IRIX_CAP + void + irix_set_cap(const char * cap_string) + { + cap_t running_cap; + if(cap_string == NULL) + fatal("irix_set_cap received NULL for input!"); + if(sysconf(_SC_CAP) != 0) { + debug("irix_set_cap: setting capability to %s",cap_string); + running_cap=cap_from_text(cap_st...
2005 May 19
2
[Bug 1043] Trusted IRIX Support
http://bugzilla.mindrot.org/show_bug.cgi?id=1043 Summary: Trusted IRIX Support Product: Portable OpenSSH Version: 4.0p1 Platform: MIPS OS/Version: IRIX Status: NEW Severity: normal Priority: P2 Component: sshd AssignedTo: bitbucket at mindrot.org ReportedBy: josterm at raytheon.com sshd
2003 Apr 20
1
log of build of 2.2.8a on Solaris9 using SUN's studio7 cc.
...al/kde/lib conftest.c -lsec -lgen -lsocket -lnsl -ldl 1>&5 "configure", line 10544: cannot find include file: <sys/capability.h> "configure", line 10545: warning: old-style declaration or incorrect type for: main "configure", line 10546: undefined symbol: cap_t "configure", line 10546: syntax error before or at: cap "configure", line 10547: undefined symbol: cap "configure", line 10547: warning: implicit function declaration: cap_get_proc "configure", line 10548: warning: implicit function declaration: exit "co...