I was able to reproduce this on master using the GeoServer* release test data*, to reproduce just perform a WMS 1.1.1. GetCapabilities, the document will contain the following links:
<OnlineResource xmlns:xlink="http://www.w3.org/1999/xlink" xlink:type="simple" xlink:href="" class="code-quote" style="color: #009100">"http://localhost:8080/geoserver/ows?request=GetLegendGraphic&format=image%2Fpng&width=20&height=20&layer=nurc%3AArc_Sample&style=raster"/>
... as you can see the service=WMS parameter is missing, this happens for all GetLegendGraphic URLs. Note that the GetLegendGraphic operation metadata is correct:
<GetLegendGraphic>
<Format>image/png</Format>
<Format>image/jpeg</Format>
<Format>application/json</Format>
<Format>image/gif</Format>
<DCPType>
<HTTP>
<Get>
<OnlineResource xmlns:xlink="http://www.w3.org/1999/xlink" xlink:type="simple" xlink:href="" class="code-quote" style="color: #009100">"http://localhost:8061/geoserver/ows?SERVICE=WMS&"/>
</Get>
</HTTP>
</DCPType>
</GetLegendGraphic>
|