Bug 250066 - Unexpected behavior of 'open' syscall
Unexpected behavior of 'open' syscall
Status: CLOSED DUPLICATE of bug 249857
Product: Fedora
Classification: Fedora
Component: kernel (Show other bugs)
7
x86_64 Linux
low Severity high
: ---
: ---
Assigned To: Kernel Maintainer List
Fedora Extras Quality Assurance
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2007-07-30 05:24 EDT by Ashish Shukla
Modified: 2007-11-30 17:12 EST (History)
0 users

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2007-07-31 17:53:12 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)
touchs.S - the AMD64 assembly language program to test (1.62 KB, application/octet-stream)
2007-07-30 05:24 EDT, Ashish Shukla
no flags Details
touch.c (480 bytes, text/plain)
2007-07-30 05:26 EDT, Ashish Shukla
no flags Details

  None (edit)
Description Ashish Shukla 2007-07-30 05:24:09 EDT
Description of problem:
'open' syscall behaves unexpectedly, with arguments a non-existent file name,
(O_WRONLY|O_CREAT|O_TRUNC), and 0600.

Version-Release number of selected component (if applicable):
kernel-2.6.22.1-33.fc7

How reproducible:
Reproducible everytime.

Steps to Reproduce:
1. Compile the attached "touchs.S" amd64 assembly language file, using following
command:

-- begin command --
wahjava@chatteau ~ $ gcc -nostdlib -nostdinc -g -o touchs touchs.S
-- end command --

2. Execute the following command, "/tmp/_xnyt8ty8erty8y" is a non-existent file
to be created.

-- begin command --
wahjava@chatteau ~ $ ./touchs "/tmp/_xnyt8ty8erty8y" && ls -l
"/tmp/_xnyt8ty8erty8y" && date
-- end command --

  
Actual results:

Output of the command executed in step 2 is following:

-- begin output --
-rw------- 1 wahjava wahjava 0 2007-07-30 19:48 /tmp/_xnyt8ty8erty8y
Mon Jul 30 14:44:28 IST 2007
-- end output --

Expected results:

Output of the command executed on Debian Etch (2.6.18-4-amd64) kernel in step 2:

-- begin output --
-rw------- 1 wahjava wahjava 0 2007-07-30 14:44 /tmp/_xnyt8ty8erty8y
Mon Jul 30 14:44:15 IST 2007
-- end output --

Additional info:
The reason of unexpected behavior of 'sudo' is due to this bug.
https://bugzilla.redhat.com/bugzilla/show_bug.cgi?id=249878
Comment 1 Ashish Shukla 2007-07-30 05:24:10 EDT
Created attachment 160225 [details]
touchs.S - the AMD64 assembly language program to test
Comment 2 Ashish Shukla 2007-07-30 05:26:34 EDT
Created attachment 160226 [details]
touch.c

'C' Program contains timestamping stuff from sources of 'sudo' package
Comment 3 Chuck Ebbert 2007-07-31 17:53:12 EDT

*** This bug has been marked as a duplicate of 249857 ***

Note You need to log in before you can comment on or make changes to this bug.