<html xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns:m="http://schemas.microsoft.com/office/2004/12/omml" xmlns="http://www.w3.org/TR/REC-html40">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=us-ascii">
<meta name="Generator" content="Microsoft Word 15 (filtered medium)">
<!--[if !mso]><style>v\:* {behavior:url(#default#VML);}
o\:* {behavior:url(#default#VML);}
w\:* {behavior:url(#default#VML);}
.shape {behavior:url(#default#VML);}
</style><![endif]--><style><!--
/* Font Definitions */
@font-face
        {font-family:"Cambria Math";
        panose-1:2 4 5 3 5 4 6 3 2 4;}
@font-face
        {font-family:Calibri;
        panose-1:2 15 5 2 2 2 4 3 2 4;}
@font-face
        {font-family:Consolas;
        panose-1:2 11 6 9 2 2 4 3 2 4;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
        {margin:0in;
        font-size:11.0pt;
        font-family:"Calibri",sans-serif;}
h2
        {mso-style-priority:9;
        mso-style-link:"Heading 2 Char";
        mso-margin-top-alt:auto;
        margin-right:0in;
        mso-margin-bottom-alt:auto;
        margin-left:0in;
        font-size:18.0pt;
        font-family:"Calibri",sans-serif;
        font-weight:bold;}
a:link, span.MsoHyperlink
        {mso-style-priority:99;
        color:blue;
        text-decoration:underline;}
code
        {mso-style-priority:99;
        font-family:"Courier New";}
pre
        {mso-style-priority:99;
        mso-style-link:"HTML Preformatted Char";
        margin:0in;
        font-size:10.0pt;
        font-family:"Courier New";}
span.Heading2Char
        {mso-style-name:"Heading 2 Char";
        mso-style-priority:9;
        mso-style-link:"Heading 2";
        font-family:"Calibri Light",sans-serif;
        color:#2F5496;}
span.HTMLPreformattedChar
        {mso-style-name:"HTML Preformatted Char";
        mso-style-priority:99;
        mso-style-link:"HTML Preformatted";
        font-family:Consolas;}
span.EmailStyle24
        {mso-style-type:personal-reply;
        font-family:"Calibri",sans-serif;
        color:windowtext;}
.MsoChpDefault
        {mso-style-type:export-only;
        font-size:10.0pt;}
@page WordSection1
        {size:8.5in 11.0in;
        margin:1.0in 1.0in 1.0in 1.0in;}
div.WordSection1
        {page:WordSection1;}
--></style><!--[if gte mso 9]><xml>
<o:shapedefaults v:ext="edit" spidmax="1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
<o:shapelayout v:ext="edit">
<o:idmap v:ext="edit" data="1" />
</o:shapelayout></xml><![endif]-->
</head>
<body lang="EN-US" link="blue" vlink="purple" style="word-wrap:break-word">
<div class="WordSection1">
<p class="MsoNormal">Just wanted to see if there were any other perspectives. MapServer itself doesn’t accept HEAD requests, nor does it seem possible. It’s Apache is returning the 200 on an HEAD request saying that the document (i.e. the cgi script) exists.
 My inclination is to close the ticket as invalid. <o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal">--Steve<o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<div>
<div style="border:none;border-top:solid #E1E1E1 1.0pt;padding:3.0pt 0in 0in 0in">
<p class="MsoNormal"><b>From:</b> pgneogeo <notifications@github.com> <br>
<b>Sent:</b> Tuesday, February 7, 2023 7:57 AM<br>
<b>To:</b> MapServer/MapServer <MapServer@noreply.github.com><br>
<b>Cc:</b> Subscribed <subscribed@noreply.github.com><br>
<b>Subject:</b> [MapServer/MapServer] Use of HEAD enstead of GET return different headers (Issue #6826)<o:p></o:p></p>
</div>
</div>
<p class="MsoNormal"><o:p> </o:p></p>
<table class="MsoNormalTable" border="0" cellspacing="0" cellpadding="0" align="left" width="100%" style="width:100.0%">
<tbody>
<tr>
<td style="background:#FFC845;padding:5.25pt 1.5pt 5.25pt 1.5pt"></td>
<td width="100%" style="width:100.0%;background:#FFF3DD;padding:5.25pt 3.75pt 5.25pt 11.25pt">
<div>
<div>
<p class="MsoNormal" style="mso-element:frame;mso-element-frame-hspace:2.25pt;mso-element-wrap:around;mso-element-anchor-vertical:paragraph;mso-element-anchor-horizontal:column;mso-height-rule:exactly">
<b><span style="color:#003865">This message may be from an external email source.</span></b><span style="color:#003865"><o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal" style="mso-element:frame;mso-element-frame-hspace:2.25pt;mso-element-wrap:around;mso-element-anchor-vertical:paragraph;mso-element-anchor-horizontal:column;mso-height-rule:exactly">
<span style="font-size:9.0pt;color:#003865">Do not select links or open attachments unless verified. Report all suspicious emails to Minnesota IT Services Security Operations Center.<o:p></o:p></span></p>
</div>
</div>
</td>
</tr>
</tbody>
</table>
<p class="MsoNormal"><o:p> </o:p></p>
<div class="MsoNormal" align="center" style="text-align:center">
<hr size="2" width="100%" align="center">
</div>
<div>
<h2>Expected behavior and actual behavior.<o:p></o:p></h2>
<p>Using GET and HEAD as HTTP commands should return the same headers.<o:p></o:p></p>
<h2>Steps to reproduce the problem.<o:p></o:p></h2>
<p>Mapserver is behind apache, with the only interesting configuration is :<o:p></o:p></p>
<pre><code>   RewriteEngine on<o:p></o:p></code></pre>
<pre><code>    RewriteRule ^/maps/([^/]*)$ /wxs/mapserv?map=/maps/$1.map [PT,QSA]<o:p></o:p></code></pre>
<p>The version installed is 7.6.2<o:p></o:p></p>
<p>When I call my server with curl, for example with this call, I receive a png, with the according header
<code><span style="font-size:10.0pt">Content-Type: image/png</span></code><o:p></o:p></p>
<p><code><span style="font-size:10.0pt">curl <a href="https://[MYDOMAIN]/maps/osm-default/?VERSION\=1.1.1\&REQUEST\=GetMap\&LAYERS\=default\&WIDTH\=256\&HEIGHT\=256\&FORMAT\=image/png\&SRS\=EPSG:3857\&BBOX\=670199.864,6227477.568,675091.833,6232369.538">
https://[MYDOMAIN]/maps/osm-default\?VERSION\=1.1.1\&REQUEST\=GetMap\&LAYERS\=default\&WIDTH\=256\&HEIGHT\=256\&FORMAT\=image/png\&SRS\=EPSG:3857\&BBOX\=670199.864,6227477.568,675091.833,6232369.538</a></span></code><o:p></o:p></p>
<p>When I call the exact same url with <code><span style="font-size:10.0pt">curl -I</span></code> to receive only the headers (for monitoring purpose), the headers are different, especially the Content-Type :
<code><span style="font-size:10.0pt">Content-Type: text/html</span></code><o:p></o:p></p>
<p>The difference is that curl use the command HEAD instead of GET, but the headers should be equivalent.<o:p></o:p></p>
<h2>Operating system<o:p></o:p></h2>
<p>Debian bullseye 64 bit<o:p></o:p></p>
<h2>MapServer version and installation method<o:p></o:p></h2>
<p>7.6.2 version, I am not sure of the way it was installed<o:p></o:p></p>
<p style="-webkit-text-size-adjust:none"><span style="font-size:12.0pt;color:#666666">—<br>
Reply to this email directly, <a href="https://gcc02.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2FMapServer%2FMapServer%2Fissues%2F6826&data=05%7C01%7Csteve.lime%40state.mn.us%7C6f25f6c40e5942d2212608db09132d7f%7Ceb14b04624c445198f26b89c2159828c%7C0%7C0%7C638113750203456390%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C3000%7C%7C%7C&sdata=AUF8QZNnegDk52iGhP6W8yLnobqqURR3Z2ie2QgGHAA%3D&reserved=0">
view it on GitHub</a>, or <a href="https://gcc02.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fnotifications%2Funsubscribe-auth%2FAAMGN63FTCSPJGSPGXEDK6DWWJICRANCNFSM6AAAAAAUT75DNI&data=05%7C01%7Csteve.lime%40state.mn.us%7C6f25f6c40e5942d2212608db09132d7f%7Ceb14b04624c445198f26b89c2159828c%7C0%7C0%7C638113750203456390%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C3000%7C%7C%7C&sdata=QefxcSCmmEHDP28SJkgkEgCenvH3kKPNA97%2BOEjoPVQ%3D&reserved=0">
unsubscribe</a>.<br>
You are receiving this because you are subscribed to this thread.</span><span style="font-size:12.0pt;color:#666666"><img border="0" width="1" height="1" style="width:.0104in;height:.0104in" id="_x0000_i1026" src="https://github.com/notifications/beacon/AAMGN67DKFJEKMGLFFWU77DWWJICRA5CNFSM6AAAAAAUT75DNKWGG33NNVSW45C7OR4XAZNFJFZXG5LFVJRW63LNMVXHIX3JMTHF3VZMBM.gif"></span><span style="font-size:1.0pt;color:#666666">Message
 ID: <<a href="mailto:MapServer/MapServer/issues/6826@github.com">MapServer/MapServer/issues/6826@github.com</a>></span><span style="font-size:12.0pt;color:#666666"><o:p></o:p></span></p>
</div>
</div>
</body>
</html>