Bug #81447 [NEW]: php8.1-fpm ERROR: Unable to open primary script

From: Date: Thu, 16 Sep 2021 14:58:03 +0000
Subject: Bug #81447 [NEW]: php8.1-fpm ERROR: Unable to open primary script
Groups: php.bugs 
Request: Send a blank email to php-bugs+get-236649@lists.php.net to get a copy of this message
From:             vyboh at zoner dot com
Operating system: Debian 10.10
PHP version:      8.1.0RC1
Package:          FPM related
Bug Type:         Bug
Bug description:php8.1-fpm ERROR: Unable to open primary script

Description:
------------
I have file:

trialhosting:/# stat /www/sites/2/site75302/public_html/info.php
  File: /www/sites/2/site75302/public_html/info.php
  Size: 25              Blocks: 8          IO Block: 4096   regular
file
Device: 851h/2129d      Inode: 168047394   Links: 1
Access: (0660/-rw-rw----)  Uid: (175302/site75302)   Gid:
(175302/site75302)

I called url: https://floyd.php5.cz/info.php
and then I hooked the php-fpm process

trialhosting:/# ltrace -S -s 200  -p 102770
(some lines skipped)
strcasecmp("files", "files")                                            
                                                                        
 = 0
strlen("/www/sites/2/site75302/public_html/info.php")                   
                                                                        
 = 43
strlen(".php")                                                          
                                                                        
 = 4
strcmp(".php", ".php")                                                  
                                                                        
 = 0
strlen("/www/sites/2/site75302/public_html/info.php")                   
                                                                        
 = 43
memcpy(0x7f1a7b002030, "/www/sites/2/site75302/public_html/info.php\0",
44)                                                                     
  = 0x7f1a7b002030
strlen("/www/sites/2/site75302/public_html")                            
                                                                        
 = 34
strlen("/info.php")                                                     
                                                                        
 = 9
memcpy(0x7f1a7b065000, "/www/sites/2/site75302/public_html", 34)        
                                                                        
 = 0x7f1a7b065000
strncpy(0x7f1a7b06503a, "/info.php", 10)                                
                                                                        
 = 0x7f1a7b06503a
SYS_getcwd("/", 4096)                                                   
                                                                        
 = 2
SYS_fcntl(3, 6, 0x7ffd03b8bb10, 0x65000)                                
                                                                        
 = 0
strlen("ublic_html")                                                    
                                                                        
 = 10
_setjmp(0x7ffd03b8c1b0, 0x7f1a7b000000, 0x7f1a7b002060, 0x7ffd03b8c010) 
                                                                        
 = 0
__errno_location()                                                      
                                                                        
 = 0x7f1a7b3be1c0
strerror(0)                                                             
                                                                        
 = "Success"
__ctype_b_loc()                                                         
                                                                        
 = 0x7f1a7b3be1d8
strlen("/www/sites/2/site75302/public_html/info.php")                   
                                                                        
 = 43
__ctype_b_loc()                                                         
                                                                        
 = 0x7f1a7b3be1d8
strlen("Success")                                                       
                                                                        
 = 7
memcpy(0x556f9b2ceed0, "Unable to open primary script:
/www/sites/2/site75302/public_html/info.php (Success)", 84)             
                   = 0x556f9b2ceed0
(some lines skipped)


In strlen("ublic_html") missing character "p" on the beginning.



-- 
Edit bug report at https://bugs.php.net/bug.php?id=81447&edit=1
-- 
Fix committed:                    https://bugs.php.net/fix.php?id=81447&r=fixed
Fixed in release:                 https://bugs.php.net/fix.php?id=81447&r=alreadyfixed
Need backtrace:                   https://bugs.php.net/fix.php?id=81447&r=needtrace
Need Reproduce Script:            https://bugs.php.net/fix.php?id=81447&r=needscript
Try newer version:                https://bugs.php.net/fix.php?id=81447&r=oldversion
Not developer issue:              https://bugs.php.net/fix.php?id=81447&r=support
Expected behavior:                https://bugs.php.net/fix.php?id=81447&r=notwrong
Not enough info:                  https://bugs.php.net/fix.php?id=81447&r=notenoughinfo
Submitted twice:                  https://bugs.php.net/fix.php?id=81447&r=submittedtwice
register_globals:                 https://bugs.php.net/fix.php?id=81447&r=globals
PHP version support discontinued: https://bugs.php.net/fix.php?id=81447&r=phptooold
Daylight Savings:                 https://bugs.php.net/fix.php?id=81447&r=dst
IIS Stability:                    https://bugs.php.net/fix.php?id=81447&r=isapi
Install GNU Sed:                  https://bugs.php.net/fix.php?id=81447&r=gnused
Floating point limitations:       https://bugs.php.net/fix.php?id=81447&r=float
No Zend Extensions:               https://bugs.php.net/fix.php?id=81447&r=nozend
MySQL Configuration Error:        https://bugs.php.net/fix.php?id=81447&r=mysqlcfg


Thread (3 messages)

« previous php.bugs (#236649) next »