DaemonForums  

Go Back   DaemonForums > OpenBSD > OpenBSD General

OpenBSD General Other questions regarding OpenBSD which do not fit in any of the categories below.

Reply
 
Thread Tools Display Modes
  #1   (View Single Post)  
Old 15th February 2020
jonsec jonsec is offline
Fdisk Soldier
 
Join Date: Jul 2019
Posts: 71
Angry OpenBSD and php header Content-Length

hi.

why httpd not set Content-Length in dynamic page like php and only set in static page!

i need implement download with resume feature but httpd is stubborn .

PHP Code:
ini_set('zlib.output_compression''Off');
ob_start();
echo 
'aaaaabbbbcccc';
ob_end_flush();
header('Content-Length: ' ob_get_length());  
ob_end_flush(); 
after most research , i find this link :
http://openbsd-archive.7691.n7.nabbl...-td306507.html
Reply With Quote
  #2   (View Single Post)  
Old 15th February 2020
jggimi's Avatar
jggimi jggimi is offline
More noise than signal
 
Join Date: May 2008
Location: USA
Posts: 7,983
Default

Quote:
Originally Posted by jonsec View Post
why...
This is best asked on the misc@ mailing list. We have only one active member who is an OpenBSD developer.

You may use a different webserver if httpd(8) does not meet the needs of your use-case. I previously used nginx on one of my servers because I needed client certificate support, which httpd() did not obtain until OpenBSD release 6.4
Reply With Quote
  #3   (View Single Post)  
Old 15th February 2020
jonsec jonsec is offline
Fdisk Soldier
 
Join Date: Jul 2019
Posts: 71
Exclamation

oooops. this is a bad news. my heart breaked ((

accordion on this line /usr.sbin/httpd/server_fcgi.c#L409

if change HTTP version to 1.0 then chunk disabled. seems this feature in openbsd is forced.

but http version not change when i set this line in httpd.conf :

Code:
location match "^.+%.php$" {
    fastcgi socket "/run/php-fpm-main.sock"
    fastcgi param SERVER_PROTOCOL "HTTP/1.0"
}
i can change this ? or move to apache...

i want use openbsd built-in components because i love help to grow OpenBSD even this grow should be 0.00005. because OpenBSD thinking is beautiful.

Last edited by jonsec; 15th February 2020 at 05:01 PM.
Reply With Quote
Reply

Tags
content-length, httpd


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Content Filtering with OpenBSD alpha202ej OpenBSD Security 4 21st December 2011 01:38 PM
PF - packets filtering by length? magnesik OpenBSD Security 3 3rd July 2011 12:46 PM
Apache: problem with rewritten content-type header Malakim General software and network 2 3rd December 2008 07:51 PM


All times are GMT. The time now is 07:32 AM.


Powered by vBulletin® Version 3.8.4
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Content copyright © 2007-2010, the authors
Daemon image copyright ©1988, Marshall Kirk McKusick