[mod_python] How check permissions to GET JPG image

Enot enotus at tut.by
Tue Dec 6 08:15:15 EST 2005


Hello Mike,

>> I need check permissions to GET JPG images and ZIP files.
ML> Use any authorization/authentication scheme you like. ...

Its OK with authorization.

>> After that i need convert JPG image name and URL to internal form.
ML> No idea what you mean ???

Request URL "http://www.hostname.org/Article/ArticleOne/Image1.jpg"
after authorization i need seend "c://webdir/Images/Article_ArticleOne_Image1.jpg"

How redirect Apache or use req.sendfile() with resume?


>> When I use req.sendfile() all works exept for download resume. After
>> download stops at middle, resume is impossibe. Error in download
>> manager when trying resume.
ML> You will probably have to implement the HTTP/1.1 "Range" header. Is not
ML> hard to program, but will take a little finger typing. Find the HTTP RFC
ML> 2616, and look for "Range".

How i can access HTTP/1.1 "Range" header from mod_python? I found
nothing about "Range" header. "req.range" always "None",
"req.headers_out" do nothing at least when using with
"req.sendfile()".
As i understand, Apache or rewrite header when using "req.sendfile()".
And this is main problem.


Thanks,
Enot                            mailto:enotus at tut.by



More information about the Mod_python mailing list