search for: closelog

Displaying 20 results from an estimated 39 matches for "closelog".

2016 Mar 28
2
Is it possible to extend log message?
...defined(HAVE_OPENLOG_R) && defined(SYSLOG_DATA_INIT) openlog_r(argv0 ? argv0 : __progname, LOG_PID, log_facility, &sd - syslog_r(pri, &sdata, "%.500s", fmtbuf); + syslog_r(pri, &sdata, "%s", fmtbuf); closelog_r(&sdata); #else openlog(argv0 ? argv0 : __progname, LOG_PID, log_facility); - syslog(pri, "%.500s", fmtbuf); + syslog(pri, "%s", fmtbuf); closelog(); #endif } Thanks nakai
2016 Jan 06
0
[klibc:master] Remove obsolete getpt() function
...521038 100644 --- a/usr/klibc/Kbuild +++ b/usr/klibc/Kbuild @@ -52,7 +52,7 @@ klib-y += vsnprintf.o snprintf.o vsprintf.o sprintf.o \ getenv.o setenv.o putenv.o __put_env.o unsetenv.o \ clearenv.o nullenv.o \ getopt.o getopt_long.o readdir.o scandir.o alphasort.o remove.o \ - syslog.o closelog.o pty.o getpt.o posix_openpt.o isatty.o reboot.o \ + syslog.o closelog.o pty.o posix_openpt.o isatty.o reboot.o \ time.o utime.o lseek.o nice.o getpriority.o \ qsort.o bsearch.o \ lrand48.o jrand48.o mrand48.o nrand48.o srand48.o seed48.o \ diff --git a/usr/klibc/getpt.c b/usr/klibc/g...
2016 Jan 27
0
[klibc:master] Make posix_openpt() an inline
...ba6add 100644 --- a/usr/klibc/Kbuild +++ b/usr/klibc/Kbuild @@ -52,7 +52,7 @@ klib-y += vsnprintf.o snprintf.o vsprintf.o sprintf.o \ getenv.o setenv.o putenv.o __put_env.o unsetenv.o \ clearenv.o nullenv.o \ getopt.o getopt_long.o readdir.o scandir.o alphasort.o remove.o \ - syslog.o closelog.o pty.o posix_openpt.o isatty.o reboot.o \ + syslog.o closelog.o pty.o isatty.o reboot.o \ time.o utime.o lseek.o nice.o getpriority.o \ qsort.o bsearch.o \ lrand48.o jrand48.o mrand48.o nrand48.o srand48.o seed48.o \ diff --git a/usr/klibc/posix_openpt.c b/usr/klibc/posix_openpt.c de...
2024 May 12
1
[Bug 3690] New: sshd: root [priv] process sleeping leads to unprivileged child proc zombie
...illa.mindrot.org/attachment.cgi?id=3814&action=edit deadlock process call stack In the `sshd.c` file, the `grace_alarm_handler()` signal handling function calls `sigdie()`, which in turn calls `sshsigdie()`, and within this call, functions such as `shlogv()`, `do_log()`, `{openlog(), syslog(), closelog()}` are invoked. Similarly, within the main thread, the `privsep_preauth()` function calls `monitor_child_preauth()`, which then calls `auth_log()`, and this also results in calls to `{openlog(), syslog(), closelog()}`. Since these functions are not async-signal-safe and they utilize a global lock...
2004 Mar 23
2
A question on Compilation errors...
...ber': /openssh-3.8p1/log.c(113): undefined reference to `strcasecmp' ./libssh.a(log.o): In function `do_log': /openssh-3.8p1/log.c(329): undefined reference to `openlog' /openssh-3.8p1/log.c(330): undefined reference to `syslog' /openssh-3.8p1/log.c(331): undefined reference to `closelog' ./libssh.a(cipher.o): In function `cipher_by_name': /openssh-3.8p1/cipher.c(149): undefined reference to `strcasecmp' ./libssh.a(channels.o): In function `channel_prepare_select': /openssh-3.8p1/channels.c(1668): undefined reference to `howmany' ./libssh.a(packet.o): In functio...
2011 Jul 29
3
[PATCH 1/3] klibc: Add scandir() and alphasort() support.
...-42,7 +42,7 @@ klib-y := vsnprintf.o snprintf.o vsprintf.o sprintf.o \ seteuid.o setegid.o \ getenv.o setenv.o putenv.o __put_env.o unsetenv.o \ clearenv.o nullenv.o \ - getopt.o getopt_long.o readdir.o remove.o \ + getopt.o getopt_long.o readdir.o scandir.o remove.o \ syslog.o closelog.o pty.o getpt.o posix_openpt.o isatty.o reboot.o \ time.o utime.o llseek.o nice.o getpriority.o \ qsort.o bsearch.o \ diff --git a/usr/klibc/scandir.c b/usr/klibc/scandir.c new file mode 100644 index 0000000..1f58b15 --- /dev/null +++ b/usr/klibc/scandir.c @@ -0,0 +1,76 @@ +/* + * scandir.c...
2005 Jan 17
19
[Bug 973] sshd behaves differently while doing syslog entries for tcpwrappers denied message, with -r and without -r option.
http://bugzilla.mindrot.org/show_bug.cgi?id=973 Summary: sshd behaves differently while doing syslog entries for tcpwrappers denied message, with -r and without -r option. Product: Portable OpenSSH Version: 3.9p1 Platform: All OS/Version: All Status: NEW Severity: normal
2008 Aug 27
0
[PATCH] stubdom: add v?errx? and v?warnx? functions
...t char *fmt, va_list args); +void vwarnx(const char *fmt, va_list args); + +#endif /* _POSIX_ERR_H */ diff -r 14a9a1629590 extras/mini-os/lib/sys.c --- a/extras/mini-os/lib/sys.c Wed Aug 27 10:26:50 2008 +0100 +++ b/extras/mini-os/lib/sys.c Wed Aug 27 10:29:36 2008 +0100 @@ -1035,6 +1035,68 @@ void closelog(void) syslog_ident = NULL; } +void vwarn(const char *format, va_list ap) +{ + int the_errno = errno; + printk("stubdom: "); + if (format) { + print(0, format, ap); + printk(", "); + } + printk("%s", strerror(the_errno)); +} + +void...
2008 Mar 19
2
I got a strange "connection refused"
Hi everybody, I got a strange error message when I used the openssh. When I run it with debug mode, like this: # /usr/local/sbin/sshd -d I can open the session via ssh command. However, when I run with daemon mode, the ssh client was closed down and threw out the following message: debug1: dispatch_run:dispatch done debug1: Authentication succeeded (keyboard-interactive). debug1: channel 0:
2010 Jun 26
1
Problem in "porting" a function on windows to linux?
Hi all! I use ubuntu 9.04; I have a function called "isLogEnabled" in my project on windows, I wanna port it to linux. I know that I should have a "config.h" file in linux to get log from a specific Shared object and ..., but because I'm new to linux, I don't know how this should be done, this is my function: Code: //This function return True if log policy is set in
1997 Feb 18
0
Abuse of the syslog facility
...r=2826\0"; const char *mesg2 ="end_request: I/O error, dev 03:00, sector 2826\0"; const char *mesg3 = "EXT2-fs: group descriptors corrupted !\0"; openlog("kernel", LOG_CONS, LOG_KERN); syslog(LOG_ERR, mesg1); syslog(LOG_ERR, mesg2); syslog(LOG_ERR, mesg3); closelog(); } --------------------------------- If one does "chmod o-rw /dev/log" that stops the above message from ending up in the log. However if the user runs the above in a tight loop, i.e. "while true; do fake_message;done" then syslogd apparently can''t keep up and by def...
2014 Jul 31
0
[PATCH 1/3] __progname is provided by libc
...| LOG_NDELAY, LOG_DAEMON); + openlog(tftpd_progname, LOG_PID | LOG_NDELAY, LOG_DAEMON); srand(time(NULL) ^ getpid()); @@ -938,14 +938,14 @@ int main(int argc, char **argv) syslog daemon gets restarted by the time we get here. */ if (secure && standalone) { closelog(); - openlog(__progname, LOG_PID | LOG_NDELAY, LOG_DAEMON); + openlog(tftpd_progname, LOG_PID | LOG_NDELAY, LOG_DAEMON); } #ifdef HAVE_TCPWRAPPERS /* Verify if this was a legal request for us. This has to be done before the chroot, while /etc is still accessible....
2001 Jul 27
0
openssh-2.9p2 compilation on LynxOS
.../log.c(108): undefined reference to `strcasecmp' ./libssh.a(log.o): In function `do_log': /openssh/openssh-2.9p2/log.c(383): undefined reference to `openlog' /openssh/openssh-2.9p2/log.c(384): undefined reference to `syslog' /openssh/openssh-2.9p2/log.c(385): undefined reference to `closelog' ./libssh.a(cipher.o): In function `cipher_by_name': /openssh/openssh-2.9p2/cipher.c(440): undefined reference to `strcasecmp' ./libssh.a(packet.o): In function `packet_read': /openssh/openssh-2.9p2/packet.c(692): undefined reference to `howmany' /openssh/openssh-2.9p2/packet.c(...
2011 Aug 02
6
[PATCH v2 0/4] Support drop directories directly from kinit
This patchset applies to klibc mainline. This patchset introduces the ability to kinit to execute scripts or executable files present in in the initramfs before switching over to the root filesystem. It is implemented by first implementing scandir() and alphasort() as present in POSIX.1-2008 in klibc itself, and then using that as the basis for iterating and executing files via a run_scripts()
2011 Aug 10
1
[PATCH v2] dirent.h add fdopendir()
...rintf.o sprintf.o \ seteuid.o setegid.o \ getenv.o setenv.o putenv.o __put_env.o unsetenv.o \ clearenv.o nullenv.o \ - getopt.o getopt_long.o readdir.o scandir.o alphasort.o remove.o \ + getopt.o getopt_long.o \ + readdir.o scandir.o fdopendir.o alphasort.o remove.o \ syslog.o closelog.o pty.o getpt.o posix_openpt.o isatty.o reboot.o \ time.o utime.o llseek.o nice.o getpriority.o \ qsort.o bsearch.o \ diff --git a/usr/klibc/fdopendir.c b/usr/klibc/fdopendir.c new file mode 100644 index 0000000..e22cba8 --- /dev/null +++ b/usr/klibc/fdopendir.c @@ -0,0 +1,40 @@ +#include &...
2012 May 19
2
Syslog via UDP for chrooted environments
Good afternoon. I'm new to the list, so apologies in advance if the noob in me comes through too loudly. >From things I've read in the distant past, I have the impression that the OpenSSH project tries to keep new features to a minimum, and there are good security reasons to do this. That said, one feature that I feel would be a good addition to OpenSSH is the ability to send logs via
1998 Jul 14
0
Slackware Shadow Insecurity (fwd)
...m the /etc/group file. */ if (initgroups (info->pw_name, info->pw_gid) == -1) { perror("initgroups"); SYSLOG((LOG_ERR, "initgroups failed for user `%s': %m\n", info->pw_name)); closelog(); return -1; } [snip] And src/login.c line 960: setup_uid_gid(&pwent, is_console); Does this look bad to anyone else? The call to setup_uid_gid() in login.c does no checking of the return value. If initgroups cannot open /etc/group, the setup_uid_gid() functi...
1997 May 26
1
an anti-overflow wrapper
...syslog(LOG_ALERT, "WRAPPER: Security violation: argument too long." "(uid = %d, euid = %d)", (int) getuid(), (int) geteuid()); exit(1); } } } else { /* syntax error */ syntax("Unknown check."); exit(1); } } } fclose(cfgfile); closelog(); execv(REALPROG ".wrapped", argv); syslog(LOG_ERR, "WRAPPER: can''t exec %s: %m.", REALPROG ".wrapped"); exit(1); } ------------------------------ Makefile ------------------------------ SUID_PROGS=/usr/X11R6/bin/xterm CFLAGS=-Wall -Wstrict-prototyp...
2007 Aug 15
0
[git patch] fstype support + minor stuff
...r.o \ - strxspn.o strspn.o strcspn.o strpbrk.o strsep.o strtok.o \ - fnmatch.o \ - gethostname.o getdomainname.o getcwd.o \ - seteuid.o setegid.o \ - getenv.o setenv.o putenv.o __put_env.o unsetenv.o \ - clearenv.o nullenv.o \ - getopt.o getopt_long.o readdir.o remove.o \ - syslog.o closelog.o pty.o getpt.o isatty.o reboot.o \ - time.o utime.o llseek.o nice.o getpriority.o \ - qsort.o bsearch.o \ - lrand48.o jrand48.o mrand48.o nrand48.o srand48.o seed48.o \ - inet/inet_ntoa.o inet/inet_aton.o inet/inet_addr.o \ - inet/inet_ntop.o inet/inet_pton.o inet/bindresvport.o \ - se...
2009 Sep 05
5
[tftpd PATCH 0/5] pidfile option and syslog fix
Hi, This is my current patch queue. The patches are independent, AFAIK, so feel free to cherry-pick or reject them independently. The bottom one was needed for a successful build here; the top one contains all the modifications you requested on IRC, and more. Meanwhile I hit one of the four stray TABs in tftpd.c, and decided to get rid of them. Comments welcome. --- Ferenc Wagner (5):