Linux vps-61133.fhnet.fr 4.9.0-19-amd64 #1 SMP Debian 4.9.320-2 (2022-06-30) x86_64
Apache/2.4.25 (Debian)
Server IP : 93.113.207.21 & Your IP : 216.73.216.152
Domains :
Cant Read [ /etc/named.conf ]
User : www-data
Terminal
Auto Root
Create File
Create Folder
Localroot Suggester
Backdoor Destroyer
Readme
/
usr /
src /
php-7.4.33 /
sapi /
fpm /
fpm /
Delete
Unzip
Name
Size
Permission
Date
Action
events
[ DIR ]
drwxrwxr-x
2022-10-31 11:36
fpm.c
2.78
KB
-rw-rw-r--
2022-10-31 11:36
fpm.h
1.07
KB
-rw-rw-r--
2022-10-31 11:36
fpm_arrays.h
1.76
KB
-rw-rw-r--
2022-10-31 11:36
fpm_atomic.h
3.9
KB
-rw-rw-r--
2022-10-31 11:36
fpm_children.c
11.38
KB
-rw-rw-r--
2022-10-31 11:36
fpm_children.h
857
B
-rw-rw-r--
2022-10-31 11:36
fpm_cleanup.c
782
B
-rw-rw-r--
2022-10-31 11:36
fpm_cleanup.h
452
B
-rw-rw-r--
2022-10-31 11:36
fpm_clock.c
2.17
KB
-rw-rw-r--
2022-10-31 11:36
fpm_clock.h
175
B
-rw-rw-r--
2022-10-31 11:36
fpm_conf.c
51.25
KB
-rw-rw-r--
2022-10-31 11:36
fpm_conf.h
2.5
KB
-rw-rw-r--
2022-10-31 11:36
fpm_config.h
2.04
KB
-rw-rw-r--
2022-10-31 11:36
fpm_env.c
5.39
KB
-rw-rw-r--
2022-10-31 11:36
fpm_env.h
428
B
-rw-rw-r--
2022-10-31 11:36
fpm_events.c
12.4
KB
-rw-rw-r--
2022-10-31 11:36
fpm_events.h
1.53
KB
-rw-rw-r--
2022-10-31 11:36
fpm_log.c
11.46
KB
-rw-rw-r--
2022-10-31 11:36
fpm_log.h
227
B
-rw-rw-r--
2022-10-31 11:36
fpm_main.c
59.7
KB
-rw-rw-r--
2022-10-31 11:36
fpm_php.c
6.03
KB
-rw-rw-r--
2022-10-31 11:36
fpm_php.h
1.14
KB
-rw-rw-r--
2022-10-31 11:36
fpm_php_trace.c
4.67
KB
-rw-rw-r--
2022-10-31 11:36
fpm_php_trace.h
162
B
-rw-rw-r--
2022-10-31 11:36
fpm_process_ctl.c
13.81
KB
-rw-rw-r--
2022-10-31 11:36
fpm_process_ctl.h
1.16
KB
-rw-rw-r--
2022-10-31 11:36
fpm_request.c
7.94
KB
-rw-rw-r--
2022-10-31 11:36
fpm_request.h
1.13
KB
-rw-rw-r--
2022-10-31 11:36
fpm_scoreboard.c
8.05
KB
-rw-rw-r--
2022-10-31 11:36
fpm_scoreboard.h
2.45
KB
-rw-rw-r--
2022-10-31 11:36
fpm_shm.c
1.17
KB
-rw-rw-r--
2022-10-31 11:36
fpm_shm.h
200
B
-rw-rw-r--
2022-10-31 11:36
fpm_signals.c
7.02
KB
-rw-rw-r--
2022-10-31 11:36
fpm_signals.h
361
B
-rw-rw-r--
2022-10-31 11:36
fpm_sockets.c
12.96
KB
-rw-rw-r--
2022-10-31 11:36
fpm_sockets.h
1009
B
-rw-rw-r--
2022-10-31 11:36
fpm_status.c
17.63
KB
-rw-rw-r--
2022-10-31 11:36
fpm_status.h
1.05
KB
-rw-rw-r--
2022-10-31 11:36
fpm_stdio.c
9.02
KB
-rw-rw-r--
2022-10-31 11:36
fpm_stdio.h
604
B
-rw-rw-r--
2022-10-31 11:36
fpm_str.h
421
B
-rw-rw-r--
2022-10-31 11:36
fpm_systemd.c
3.1
KB
-rw-rw-r--
2022-10-31 11:36
fpm_systemd.h
274
B
-rw-rw-r--
2022-10-31 11:36
fpm_trace.c
524
B
-rw-rw-r--
2022-10-31 11:36
fpm_trace.h
313
B
-rw-rw-r--
2022-10-31 11:36
fpm_trace_mach.c
1.92
KB
-rw-rw-r--
2022-10-31 11:36
fpm_trace_pread.c
1.1
KB
-rw-rw-r--
2022-10-31 11:36
fpm_trace_ptrace.c
1.53
KB
-rw-rw-r--
2022-10-31 11:36
fpm_unix.c
16.22
KB
-rw-rw-r--
2022-10-31 11:36
fpm_unix.h
454
B
-rw-rw-r--
2022-10-31 11:36
fpm_worker_pool.c
1.74
KB
-rw-rw-r--
2022-10-31 11:36
fpm_worker_pool.h
1.23
KB
-rw-rw-r--
2022-10-31 11:36
zlog.c
21.7
KB
-rw-rw-r--
2022-10-31 11:36
zlog.h
3.58
KB
-rw-rw-r--
2022-10-31 11:36
Save
Rename
/* (c) 2007,2008 Andrei Nigmatulin */ #include "fpm_config.h" #ifdef HAVE_ALLOCA_H #include <alloca.h> #endif #include <stdio.h> #include <stdlib.h> #include <string.h> #include "fpm_env.h" #include "fpm.h" #ifndef HAVE_SETPROCTITLE #ifdef __linux__ static char **fpm_env_argv = NULL; static size_t fpm_env_argv_len = 0; #endif #endif #ifndef HAVE_SETENV # ifdef (__sparc__ || __sparc) int setenv(char *name, char *value, int clobber) /* {{{ */ { char *malloc(); char *getenv(); char *cp; if (clobber == 0 && getenv(name) != 0) { return 0; } if ((cp = malloc(strlen(name) + strlen(value) + 2)) == 0) { return 1; } sprintf(cp, "%s=%s", name, value); return putenv(cp); } /* }}} */ # else int setenv(char *name, char *value, int overwrite) /* {{{ */ { int name_len = strlen(name); int value_len = strlen(value); char *var = alloca(name_len + 1 + value_len + 1); memcpy(var, name, name_len); var[name_len] = '='; memcpy(var + name_len + 1, value, value_len); var[name_len + 1 + value_len] = '\0'; return putenv(var); } /* }}} */ # endif #endif #ifndef HAVE_CLEARENV void clearenv() /* {{{ */ { char **envp; char *s; /* this algo is the only one known to me that works well on all systems */ while (*(envp = environ)) { char *eq = strchr(*envp, '='); s = strdup(*envp); if (eq) s[eq - *envp] = '\0'; unsetenv(s); free(s); } } /* }}} */ #endif #ifndef HAVE_UNSETENV void unsetenv(const char *name) /* {{{ */ { if(getenv(name) != NULL) { int ct = 0; int del = 0; while(environ[ct] != NULL) { if (nvmatch(name, environ[ct]) != 0) del=ct; /* <--- WTF?! */ { ct++; } /* <--- WTF?! */ } /* isn't needed free here?? */ environ[del] = environ[ct-1]; environ[ct-1] = NULL; } } /* }}} */ static char * nvmatch(char *s1, char *s2) /* {{{ */ { while(*s1 == *s2++) { if(*s1++ == '=') { return s2; } } if(*s1 == '\0' && *(s2-1) == '=') { return s2; } return NULL; } /* }}} */ #endif void fpm_env_setproctitle(char *title) /* {{{ */ { #if defined(HAVE_SETPROCTITLE_FAST) setproctitle_fast("%s", title); #elif defined(HAVE_SETPROCTITLE) setproctitle("%s", title); #else #ifdef __linux__ if (fpm_env_argv != NULL && fpm_env_argv_len > strlen(SETPROCTITLE_PREFIX) + 3) { memset(fpm_env_argv[0], 0, fpm_env_argv_len); strncpy(fpm_env_argv[0], SETPROCTITLE_PREFIX, fpm_env_argv_len - 2); strncpy(fpm_env_argv[0] + strlen(SETPROCTITLE_PREFIX), title, fpm_env_argv_len - strlen(SETPROCTITLE_PREFIX) - 2); fpm_env_argv[1] = NULL; } #endif #endif } /* }}} */ int fpm_env_init_child(struct fpm_worker_pool_s *wp) /* {{{ */ { struct key_value_s *kv; char *title; spprintf(&title, 0, "pool %s", wp->config->name); fpm_env_setproctitle(title); efree(title); if (wp->config->clear_env) { clearenv(); } for (kv = wp->config->env; kv; kv = kv->next) { setenv(kv->key, kv->value, 1); } if (wp->user) { setenv("USER", wp->user, 1); } if (wp->home) { setenv("HOME", wp->home, 1); } return 0; } /* }}} */ static int fpm_env_conf_wp(struct fpm_worker_pool_s *wp) /* {{{ */ { struct key_value_s *kv; for (kv = wp->config->env; kv; kv = kv->next) { if (*kv->value == '$') { char *value = getenv(kv->value + 1); if (!value) { value = ""; } free(kv->value); kv->value = strdup(value); } /* autodetected values should be removed if these vars specified in config */ if (!strcmp(kv->key, "USER")) { free(wp->user); wp->user = 0; } if (!strcmp(kv->key, "HOME")) { free(wp->home); wp->home = 0; } } return 0; } /* }}} */ int fpm_env_init_main() /* {{{ */ { struct fpm_worker_pool_s *wp; char *title; for (wp = fpm_worker_all_pools; wp; wp = wp->next) { if (0 > fpm_env_conf_wp(wp)) { return -1; } } #ifndef HAVE_SETPROCTITLE #ifdef __linux__ int i; char *first = NULL; char *last = NULL; /* * This piece of code has been inspirated from nginx and pureftpd code, which * are under BSD licence. * * To change the process title in Linux we have to set argv[1] to NULL * and to copy the title to the same place where the argv[0] points to. * However, argv[0] may be too small to hold a new title. Fortunately, Linux * store argv[] and environ[] one after another. So we should ensure that is * the continuous memory and then we allocate the new memory for environ[] * and copy it. After this we could use the memory starting from argv[0] for * our process title. */ for (i = 0; i < fpm_globals.argc; i++) { if (first == NULL) { first = fpm_globals.argv[i]; } if (last == NULL || fpm_globals.argv[i] == last + 1) { last = fpm_globals.argv[i] + strlen(fpm_globals.argv[i]); } } if (environ) { for (i = 0; environ[i]; i++) { if (first == NULL) { first = environ[i]; } if (last == NULL || environ[i] == last + 1) { last = environ[i] + strlen(environ[i]); } } } if (first == NULL || last == NULL) { return 0; } fpm_env_argv_len = last - first; fpm_env_argv = fpm_globals.argv; if (environ != NULL) { char **new_environ; unsigned int env_nb = 0U; while (environ[env_nb]) { env_nb++; } if ((new_environ = malloc((1U + env_nb) * sizeof (char *))) == NULL) { return -1; } new_environ[env_nb] = NULL; while (env_nb > 0U) { env_nb--; new_environ[env_nb] = strdup(environ[env_nb]); } environ = new_environ; } #endif #endif spprintf(&title, 0, "master process (%s)", fpm_globals.config); fpm_env_setproctitle(title); efree(title); return 0; } /* }}} */