lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Tue, 29 Jan 2013 20:35:12 +0100
From:	Jiri Slaby <jslaby@...e.cz>
To:	Oleg Nesterov <oleg@...hat.com>
CC:	Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
	Lingzhu Xiang <lxiang@...hat.com>,
	Roman Rakus <rrakus@...hat.com>, linux-kernel@...r.kernel.org
Subject: Re: [PATCH 1/1] tty: set_termios/set_termiox should not return -EINTR

On 01/29/2013 08:07 PM, Oleg Nesterov wrote:
> See https://bugzilla.redhat.com/show_bug.cgi?id=904907
> read command causes bash to abort with double free or corruption (out).
> 
> A simple test-case from Roman:
> 
> 	// Compile the reproducer and send sigchld ti that process.
> 	// EINTR occurs even if SA_RESTART flag is set.
> 
> 	void handler(int sig)
> 	{
> 	}
> 
> 	main()
> 	{
> 	  struct sigaction act;
> 	  act.sa_handler = handler;
> 	  act.sa_flags = SA_RESTART;
> 	  sigaction (SIGCHLD, &act, 0);
> 	  struct termio ttp;
> 	  ioctl(0, TCGETA, &ttp);
> 	  while(1)
> 	  {
> 	    if (ioctl(0, TCSETAW, ttp) < 0)
> 	      {
> 		if (errno == EINTR)
> 		{
> 		  fprintf(stderr, "BUG!"); return(1);
> 		}
> 	      }
> 	  }
> 	}
> 
> Change set_termios/set_termiox to return -ERESTARTSYS to fix this
> particular problem.

This looks reasonable. However given the link above says:
 You are not authorized to access bug #904907.
the description above is poor. What problem exactly does this fix? Why
this should go to stable at all?

-- 
js
suse labs
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ