cronie: update to 1.5.7

This commit is contained in:
Leonid Pliushch 2021-05-03 18:43:38 +00:00
parent 05b4bd3520
commit f148e325c7
No known key found for this signature in database
GPG Key ID: 45F2964132545795
3 changed files with 67 additions and 71 deletions

View File

@ -2,10 +2,9 @@ TERMUX_PKG_HOMEPAGE=https://github.com/cronie-crond/cronie/
TERMUX_PKG_DESCRIPTION="Daemon that runs specified programs at scheduled times and related tools"
TERMUX_PKG_LICENSE="BSD"
TERMUX_PKG_MAINTAINER="@termux"
TERMUX_PKG_VERSION=1.5.5
TERMUX_PKG_REVISION=6
TERMUX_PKG_VERSION=1.5.7
TERMUX_PKG_SRCURL=https://github.com/cronie-crond/cronie/releases/download/cronie-${TERMUX_PKG_VERSION}/cronie-${TERMUX_PKG_VERSION}.tar.gz
TERMUX_PKG_SHA256=be34c79505e5544323281854744b9955ff16b160ee569f9df7c0dddae5720eac
TERMUX_PKG_SHA256=538bcfaf2e986e5ae1edf6d1472a77ea8271d6a9005aee2497a9ed6e13320eb3
TERMUX_PKG_DEPENDS="dash"
TERMUX_PKG_RECOMMENDS="nano"
TERMUX_PKG_SUGGESTS="termux-services"

View File

@ -1,6 +1,6 @@
diff -uNr cronie-1.5.5/man/cron.8 cronie-1.5.5.mod/man/cron.8
--- cronie-1.5.5/man/cron.8 2017-09-14 14:34:58.000000000 +0300
+++ cronie-1.5.5.mod/man/cron.8 2020-07-09 00:39:44.598999871 +0300
diff -uNr cronie-1.5.7/man/cron.8 cronie-1.5.7.mod/man/cron.8
--- cronie-1.5.7/man/cron.8 2017-09-14 11:34:58.000000000 +0000
+++ cronie-1.5.7.mod/man/cron.8 2021-05-03 18:31:02.488787206 +0000
@@ -27,7 +27,7 @@
crond \- daemon to execute scheduled commands
.SH SYNOPSIS
@ -167,9 +167,9 @@ diff -uNr cronie-1.5.5/man/cron.8 cronie-1.5.5.mod/man/cron.8
.SH CAVEATS
All
.BR crontab
diff -uNr cronie-1.5.5/man/cronnext.1 cronie-1.5.5.mod/man/cronnext.1
--- cronie-1.5.5/man/cronnext.1 2019-04-08 17:00:11.000000000 +0300
+++ cronie-1.5.5.mod/man/cronnext.1 2020-07-09 00:39:32.430945000 +0300
diff -uNr cronie-1.5.7/man/cronnext.1 cronie-1.5.7.mod/man/cronnext.1
--- cronie-1.5.7/man/cronnext.1 2019-04-08 14:00:11.000000000 +0000
+++ cronie-1.5.7.mod/man/cronnext.1 2021-05-03 18:31:02.488787206 +0000
@@ -33,10 +33,9 @@
.TP
.B \-s
@ -183,10 +183,10 @@ diff -uNr cronie-1.5.5/man/cronnext.1 cronie-1.5.5.mod/man/cronnext.1
.TP
.BI \-a
Use the crontabs installed in the system in addition to the ones passed as
diff -uNr cronie-1.5.5/man/crontab.1 cronie-1.5.5.mod/man/crontab.1
--- cronie-1.5.5/man/crontab.1 2019-10-31 16:50:32.000000000 +0200
+++ cronie-1.5.5.mod/man/crontab.1 2020-07-09 00:39:44.598999871 +0300
@@ -27,25 +27,14 @@
diff -uNr cronie-1.5.7/man/crontab.1 cronie-1.5.7.mod/man/crontab.1
--- cronie-1.5.7/man/crontab.1 2021-03-19 10:15:42.000000000 +0000
+++ cronie-1.5.7.mod/man/crontab.1 2021-05-03 18:35:47.696788900 +0000
@@ -27,8 +27,6 @@
crontab \- maintains crontab files for individual users
.SH SYNOPSIS
.B crontab
@ -195,6 +195,9 @@ diff -uNr cronie-1.5.5/man/crontab.1 cronie-1.5.5.mod/man/crontab.1
.RI < "file"
.RB | \ - >
.br
@@ -38,19 +36,10 @@
.RB | \ - >
.br
.B crontab
-.RB [ -u
-.IR user ]
@ -212,7 +215,7 @@ diff -uNr cronie-1.5.5/man/crontab.1 cronie-1.5.5.mod/man/crontab.1
.BR -V
.SH DESCRIPTION
.I Crontab
@@ -55,72 +44,16 @@
@@ -60,58 +49,12 @@
.BR cron (8)
daemon. Each user can have their own crontab, and though these are files
in
@ -272,6 +275,9 @@ diff -uNr cronie-1.5.5/man/crontab.1 cronie-1.5.5.mod/man/crontab.1
-.I /tmp
+.I @TERMUX_PREFIX@/tmp
directory is used.
.PP
When listing a crontab on a terminal the output will be colorized unless
@@ -121,16 +64,6 @@
.PP
.SH "OPTIONS"
.TP
@ -285,10 +291,10 @@ diff -uNr cronie-1.5.5/man/crontab.1 cronie-1.5.5.mod/man/crontab.1
-.B crontab -u
-command is used under their username.
-.TP
.B "\-l"
Displays the current crontab on standard output.
.TP
@@ -147,74 +80,11 @@
.B "\-T"
Test the crontab file syntax without installing it.
Once an issue is found, the validation is interrupted, so this will not return all the existing issues at the same execution.
@@ -161,74 +94,11 @@
documentation of MLS_LEVEL in
.BR crontab (5).
.TP

View File

@ -1,7 +1,7 @@
diff -uNr cronie-1.5.5/src/cron.c cronie-1.5.5.mod/src/cron.c
--- cronie-1.5.5/src/cron.c 2019-04-15 11:33:30.000000000 +0300
+++ cronie-1.5.5.mod/src/cron.c 2020-07-09 00:31:25.288737591 +0300
@@ -187,7 +187,9 @@
diff -uNr cronie-1.5.7/src/cron.c cronie-1.5.7.mod/src/cron.c
--- cronie-1.5.7/src/cron.c 2021-01-22 11:29:39.000000000 +0000
+++ cronie-1.5.7.mod/src/cron.c 2021-05-03 18:37:15.040789324 +0000
@@ -184,7 +184,9 @@
fprintf(stderr, " -n run in foreground\n");
fprintf(stderr, " -p permit any crontab\n");
fprintf(stderr, " -P use PATH=\"%s\"\n", _PATH_DEFPATH);
@ -11,7 +11,7 @@ diff -uNr cronie-1.5.5/src/cron.c cronie-1.5.5.mod/src/cron.c
fprintf(stderr, " -s log into syslog instead of sending mails\n");
fprintf(stderr, " -V print version and exit\n");
fprintf(stderr, " -x <flag> print debug information\n");
@@ -691,7 +693,7 @@
@@ -689,7 +691,7 @@
static void parse_args(int argc, char *argv[]) {
int argch;
@ -20,7 +20,7 @@ diff -uNr cronie-1.5.5/src/cron.c cronie-1.5.5.mod/src/cron.c
switch (argch) {
case 'x':
if (!set_debug_flags(optarg))
@@ -715,9 +717,11 @@
@@ -713,9 +715,11 @@
case 'm':
strncpy(MailCmd, optarg, MAX_COMMAND);
break;
@ -32,53 +32,44 @@ diff -uNr cronie-1.5.5/src/cron.c cronie-1.5.5.mod/src/cron.c
case 'V':
puts(PACKAGE_STRING);
exit(EXIT_SUCCESS);
diff -uNr cronie-1.5.5/src/crontab.c cronie-1.5.5.mod/src/crontab.c
--- cronie-1.5.5/src/crontab.c 2019-10-31 16:50:32.000000000 +0200
+++ cronie-1.5.5.mod/src/crontab.c 2020-07-09 00:31:25.288737591 +0300
@@ -75,15 +75,15 @@
static const char *Options[] = {"???", "list", "delete", "edit", "replace", "hostset", "hostget"};
diff -uNr cronie-1.5.7/src/crontab.c cronie-1.5.7.mod/src/crontab.c
--- cronie-1.5.7/src/crontab.c 2021-03-19 10:15:42.000000000 +0000
+++ cronie-1.5.7.mod/src/crontab.c 2021-05-03 18:40:24.992789931 +0000
@@ -81,15 +81,15 @@
};
# ifdef WITH_SELINUX
-static const char *getoptargs = "u:lerisncx:V";
+static const char *getoptargs = "u:lerisx:V";
-static const char *getoptargs = "u:lerisncx:VT";
+static const char *getoptargs = "lerisx:VT";
# else
-static const char *getoptargs = "u:lerincx:V";
+static const char *getoptargs = "u:lerix:V";
-static const char *getoptargs = "u:lerincx:VT";
+static const char *getoptargs = "lerix:VT";
# endif
#else
# ifdef WITH_SELINUX
-static const char *getoptargs = "u:lerisncV";
+static const char *getoptargs = "u:lerisV";
-static const char *getoptargs = "u:lerisncVT";
+static const char *getoptargs = "lerisVT";
# else
-static const char *getoptargs = "u:lerincV";
+static const char *getoptargs = "u:leriV";
-static const char *getoptargs = "u:lerincVT";
+static const char *getoptargs = "leriVT";
# endif
#endif
#ifdef WITH_SELINUX
@@ -115,16 +115,22 @@
fprintf(stderr, "Usage:\n");
fprintf(stderr, " %s [options] file\n", ProgramName);
fprintf(stderr, " %s [options]\n", ProgramName);
+#ifndef __ANDROID__
@@ -127,13 +127,10 @@
fprintf(stderr, " %s -n [hostname]\n", ProgramName);
+#endif
fprintf(stderr, "\n");
fprintf(stderr, "Options:\n");
+#ifndef __ANDROID__
fprintf(stderr, " -u <user> define user\n");
+#endif
- fprintf(stderr, " -u <user> define user\n");
fprintf(stderr, " -e edit user's crontab\n");
fprintf(stderr, " -l list user's crontab\n");
fprintf(stderr, " -r delete user's crontab\n");
fprintf(stderr, " -i prompt before deleting\n");
+#ifndef __ANDROID__
fprintf(stderr, " -n <host> set host in cluster to run users' crontabs\n");
fprintf(stderr, " -c get host in cluster to run users' crontabs\n");
+#endif
- fprintf(stderr, " -n <host> set host in cluster to run users' crontabs\n");
- fprintf(stderr, " -c get host in cluster to run users' crontabs\n");
fprintf(stderr, " -T <file> test a crontab file syntax\n");
#ifdef WITH_SELINUX
fprintf(stderr, " -s selinux context\n");
#endif
@@ -157,6 +163,7 @@
@@ -167,6 +164,7 @@
#endif
parse_args(argc, argv); /* sets many globals, opens a file */
check_spool_dir();
@ -86,7 +77,7 @@ diff -uNr cronie-1.5.5/src/crontab.c cronie-1.5.5.mod/src/crontab.c
if (!allowed(RealUser, CRON_ALLOW, CRON_DENY)) {
fprintf(stderr,
"You (%s) are not allowed to use this program (%s)\n",
@@ -165,7 +172,7 @@
@@ -175,7 +173,7 @@
log_it(RealUser, Pid, "AUTH", "crontab command not allowed", 0);
exit(ERROR_EXIT);
}
@ -95,7 +86,7 @@ diff -uNr cronie-1.5.5/src/crontab.c cronie-1.5.5.mod/src/crontab.c
#if defined(WITH_PAM)
if (getuid() != 0 && cron_start_pam(pw) != PAM_SUCCESS) {
fprintf(stderr,
@@ -214,7 +221,7 @@
@@ -228,7 +226,7 @@
int argch;
if (!(pw = getpwuid(getuid()))) {
@ -104,7 +95,7 @@ diff -uNr cronie-1.5.5/src/crontab.c cronie-1.5.5.mod/src/crontab.c
ProgramName);
fprintf(stderr, "bailing out.\n");
exit(ERROR_EXIT);
@@ -237,6 +244,7 @@
@@ -251,6 +249,7 @@
usage("bad debug option");
break;
#endif
@ -112,7 +103,7 @@ diff -uNr cronie-1.5.5/src/crontab.c cronie-1.5.5.mod/src/crontab.c
case 'u':
if (MY_UID(pw) != ROOT_UID) {
fprintf(stderr, "must be privileged to use -u\n");
@@ -264,6 +272,7 @@
@@ -278,6 +277,7 @@
usage("username too long");
(void) strcpy(User, optarg);
break;
@ -120,15 +111,15 @@ diff -uNr cronie-1.5.5/src/crontab.c cronie-1.5.5.mod/src/crontab.c
case 'l':
if (Option != opt_unknown)
usage("only one operation permitted");
@@ -290,6 +299,7 @@
@@ -309,6 +309,7 @@
}
break;
#endif
+#ifndef __ANDROID__
case 'n':
if (MY_UID(pw) != ROOT_UID) {
fprintf(stderr,
@@ -315,6 +325,7 @@
fprintf(stderr, "must be privileged to set host with -n\n");
@@ -331,6 +332,7 @@
}
Option = opt_hostget;
break;
@ -136,7 +127,7 @@ diff -uNr cronie-1.5.5/src/crontab.c cronie-1.5.5.mod/src/crontab.c
case 'V':
puts(PACKAGE_STRING);
exit(EXIT_SUCCESS);
@@ -630,6 +641,7 @@
@@ -663,6 +665,7 @@
goto fatal;
case 0:
/* child */
@ -144,7 +135,7 @@ diff -uNr cronie-1.5.5/src/crontab.c cronie-1.5.5.mod/src/crontab.c
if (setgid(MY_GID(pw)) < 0) {
perror("setgid(getgid())");
exit(ERROR_EXIT);
@@ -638,6 +650,7 @@
@@ -671,6 +674,7 @@
perror("setuid(getuid())");
exit(ERROR_EXIT);
}
@ -152,15 +143,15 @@ diff -uNr cronie-1.5.5/src/crontab.c cronie-1.5.5.mod/src/crontab.c
if (!glue_strings(q, sizeof q, editor, Filename, ' ')) {
fprintf(stderr, "%s: editor command line too long\n", ProgramName);
exit(ERROR_EXIT);
@@ -896,6 +909,7 @@
file_owner = (getgid() == geteuid() && getgid() == getegid()) ? ROOT_UID : pw->pw_uid;
@@ -878,6 +882,7 @@
file_owner = (getgid() == geteuid() &&
getgid() == getegid()) ? ROOT_UID : pw->pw_uid;
+#ifndef __ANDROID__
#ifdef HAVE_FCHOWN
if (fchown(fileno(tmp), file_owner, (gid_t)-1) < OK) {
perror("fchown");
@@ -911,6 +925,7 @@
@@ -893,6 +898,7 @@
goto done;
}
#endif
@ -168,9 +159,9 @@ diff -uNr cronie-1.5.5/src/crontab.c cronie-1.5.5.mod/src/crontab.c
if (fclose(tmp) == EOF) {
perror("fclose");
diff -uNr cronie-1.5.5/src/misc.c cronie-1.5.5.mod/src/misc.c
--- cronie-1.5.5/src/misc.c 2019-05-07 15:45:40.000000000 +0300
+++ cronie-1.5.5.mod/src/misc.c 2020-07-09 00:31:21.068718342 +0300
diff -uNr cronie-1.5.7/src/misc.c cronie-1.5.7.mod/src/misc.c
--- cronie-1.5.7/src/misc.c 2019-05-07 12:45:40.000000000 +0000
+++ cronie-1.5.7.mod/src/misc.c 2021-05-03 18:37:15.040789324 +0000
@@ -228,6 +228,9 @@
}
@ -205,9 +196,9 @@ diff -uNr cronie-1.5.5/src/misc.c cronie-1.5.5.mod/src/misc.c
size_t strlens(const char *last, ...) {
va_list ap;
size_t ret = 0;
diff -uNr cronie-1.5.5/src/security.c cronie-1.5.5.mod/src/security.c
--- cronie-1.5.5/src/security.c 2019-04-15 11:33:30.000000000 +0300
+++ cronie-1.5.5.mod/src/security.c 2020-07-09 00:31:25.288737591 +0300
diff -uNr cronie-1.5.7/src/security.c cronie-1.5.7.mod/src/security.c
--- cronie-1.5.7/src/security.c 2021-01-22 11:29:39.000000000 +0000
+++ cronie-1.5.7.mod/src/security.c 2021-05-03 18:37:15.040789324 +0000
@@ -235,6 +235,10 @@
}