Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1223654
| From | Sean Fu <fxinrong@gmail.com> |
|---|---|
| Newsgroups | linux.kernel |
| Subject | Re: [PATCH] kernel/sysctl.c: If "count" including the terminating byte '\0' the write system call should retrun success. |
| Date | 2015-09-13 14:40 +0200 |
| Message-ID | <q8eJB-7J8-29@gated-at.bofh.it> (permalink) |
| References | (15 earlier) <q6sQG-80Q-19@gated-at.bofh.it> <q6tWr-16N-47@gated-at.bofh.it> <q6u65-1i4-3@gated-at.bofh.it> <q7svg-5vh-21@gated-at.bofh.it> <q7zZN-7Wu-39@gated-at.bofh.it> |
| Organization | linux.* mail to news gateway |
On Sat, Sep 12, 2015 at 1:01 AM, Eric W. Biederman <ebiederm@xmission.com> wrote: > Sean Fu <fxinrong@gmail.com> writes: > >>> Sounds like a reasonable compromise. Sean, can you make a patch that >>> only affects the one proc file (comment it well in the code), and have >>> it accept nothing past the '\0'. Even if someone passed in "1 \0 2", it >>> would only see "1 " >> The current code uses uniform handler (e.g. "proc_dointvec") for all >> same type proc file. >> So all integer type proc file are affected. > > No. I do not believe the proprietary binary application you are dealing > with writes to all proc files that use the proc_dointvec handler. I means all ctl_table whose .proc_handler is "proc_dointvec" are affected. > >> In fact, The behavior of all integer type proc file should be changed. > > Not at all. The only files that we can possibly justify changing today > are the files where an actual regression is being observed. > > Because quite frankly 5 years is way too long to wait to report a > regression. By and large software is reasonable and treats proc > files as text files where '\0' is an invalid character. 5 years is not enough long for distros, specially enterprise distros. The most of HuaWei machines run our SLES10sp3(2.6.16, SUSE LINUX ENTERPRISE SERVER). They use one enterprise version for 5+ years usually. > > Accepting a '\0' is not at all reasonable for a text interface. The > application that does it is buggy. It is hard to comprehend that the current kernel can accept two bytes "1 ", "1\t", "1\n" except "1\0". > > Eric -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
Back to linux.kernel | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
Re: [PATCH] kernel/sysctl.c: If "count" including the terminating byte '\0' the write system call should retrun success. Sean Fu <fxinrong@gmail.com> - 2015-09-08 05:20 +0200
Re: [PATCH] kernel/sysctl.c: If "count" including the terminating byte '\0' the write system call should retrun success. Steven Rostedt <rostedt@goodmis.org> - 2015-09-08 17:20 +0200
Re: [PATCH] kernel/sysctl.c: If "count" including the terminating byte '\0' the write system call should retrun success. ebiederm@xmission.com (Eric W. Biederman) - 2015-09-08 18:30 +0200
Re: [PATCH] kernel/sysctl.c: If "count" including the terminating byte '\0' the write system call should retrun success. Steven Rostedt <rostedt@goodmis.org> - 2015-09-08 18:40 +0200
Re: [PATCH] kernel/sysctl.c: If "count" including the terminating byte '\0' the write system call should retrun success. Sean Fu <fxinrong@gmail.com> - 2015-09-11 11:10 +0200
Re: [PATCH] kernel/sysctl.c: If "count" including the terminating byte '\0' the write system call should retrun success. Steven Rostedt <rostedt@goodmis.org> - 2015-09-11 15:50 +0200
Re: [PATCH] kernel/sysctl.c: If "count" including the terminating byte '\0' the write system call should retrun success. ebiederm@xmission.com (Eric W. Biederman) - 2015-09-11 19:10 +0200
Re: [PATCH] kernel/sysctl.c: If "count" including the terminating byte '\0' the write system call should retrun success. Sean Fu <fxinrong@gmail.com> - 2015-09-13 14:40 +0200
Re: [PATCH] kernel/sysctl.c: If "count" including the terminating byte '\0' the write system call should retrun success. ebiederm@xmission.com (Eric W. Biederman) - 2015-09-13 19:00 +0200
Re: [PATCH] kernel/sysctl.c: If "count" including the terminating byte '\0' the write system call should retrun success. Sean Fu <fxinrong@gmail.com> - 2015-09-15 11:40 +0200
Re: [PATCH] kernel/sysctl.c: If "count" including the terminating byte '\0' the write system call should retrun success. "Eric W. Biederman" <ebiederm@xmission.com> - 2015-09-15 16:20 +0200
Re: [PATCH] kernel/sysctl.c: If "count" including the terminating byte '\0' the write system call should retrun success. Steven Rostedt <rostedt@goodmis.org> - 2015-09-13 22:10 +0200
Re: [PATCH] kernel/sysctl.c: If "count" including the terminating byte '\0' the write system call should retrun success. Sean Fu <fxinrong@gmail.com> - 2015-09-15 11:40 +0200
Re: [PATCH] kernel/sysctl.c: If "count" including the terminating byte '\0' the write system call should retrun success. Steven Rostedt <rostedt@goodmis.org> - 2015-09-15 16:00 +0200
csiph-web