Guten Tag Kevin Turner,
am Freitag, 11. Dezember 2015 um 01:21 schrieben Sie:
> The code is basically the same in 5.0.1 as it is in 5.1.0
I hoped the path part might have changed, that simply other values are
considered to be the "current path" and matched against.
> -------------------------------------------------------------
> The value of $path is "/bugzilla/rest.cgi/version"
> The webservice being checked is Bugzilla::WebService::Bugzilla
> The regex being compared is (?^:^/version$)
> Result is no match!
> -------------------------------------------------------------
From my understanding of Perl, this can't ever work with such a path.
Let's have a look at the caller:
> $self->_find_resource($self->cgi->path_info)
I'm pretty sure that "cgi" is the original CGI object of Perl:
> path_info()
> Returns additional path information from the script URL. E.G.
> fetching /cgi-bin/your_script/additional/stuff will result in
> path_info() returning "/additional/stuff".
> NOTE: The Microsoft Internet Information Server is broken with
> respect to additional path information. If you use the Perl DLL
> library, the IIS server will attempt to execute the additional path
> information as a Perl script. If you use the ordinary file
> associations mapping, the path information will be present in the
> environment, but incorrect. The best thing to do is to avoid using
> additional path information in CGI scripts destined for use with
> IIS.
http://perldoc.perl.org/CGI.html
The docs seem clear: If path_info would have worked correctly, only
"/version" would have been matched and the anchored regexp would be
OK. So I guess you suffer from the documented IIS problem.
I've found some bugs related to this problem already, though I don't
see that they address the REST webservice directly.
https://bugzilla.mozilla.org/show_bug.cgi?id=783386#c4
https://bugzilla.mozilla.org/show_bug.cgi?id=1088022
So this looks like a new bug is needed, because this seems to be newly
introduced for the REST web service. If Bugzilla::CGI already provided
a workaround in the past, that should be easily adoptable to REST.
Else the docs may should make clear that REST is unusable in IIS
currently?
And with bugs in the end you would have not completely wasted your
time without knowing the reason why it doesn't work...
https://bugzilla.readthedocs.org/en/5.0/installing/iis.html#enable-rewrite-rules-for-rest
https://www.bugzilla.org/developers/reporting_bugs.html