10-09-2019, 08:01 AM
(This post was last modified: 10-09-2019, 08:37 AM by Alexandre Machado.)
So, a little RFC just for fun:
The Common Gateway Interface (CGI) Version 1.1: https://tools.ietf.org/html/rfc3875
There we read:
Remember that there is no CGI spec for Windows. So I'm using UNIX as the base. Others are just the same.
So, we need to find out what SHOULD means in that RFC. If we go back a little, in the same RFC we read:
This is basically the same for all RFCs. Then we go to BCP 14 to find out what SHOULD means:
https://tools.ietf.org/html/bcp14
From there I quote:
As you can see, SHOULD means RECOMMENDED. It is not an obligation to fulfill the requirements. I've also included item 1 (MUST) to show that the spec would definitely use MUST, and not SHOULD, if that was a requirement of the spec. MUST is only used when it is a requirement.
On the other hand, knowing that there is no obligation to set the current directory when calling a CGI script, the CGI script developer MUST make sure that the current directory is set if the task performed by the script is sensitive to current directory setting. Whoever does it differently is lazy.
The Common Gateway Interface (CGI) Version 1.1: https://tools.ietf.org/html/rfc3875
There we read:
Quote:7.2. UNIX
The current working directory
The current working directory for the script SHOULD be set to the
directory containing the script.
Remember that there is no CGI spec for Windows. So I'm using UNIX as the base. Others are just the same.
So, we need to find out what SHOULD means in that RFC. If we go back a little, in the same RFC we read:
Quote:1.2. Requirements
The key words 'MUST', 'MUST NOT', 'REQUIRED', 'SHALL', 'SHALL NOT',
'SHOULD', 'SHOULD NOT', 'RECOMMENDED', 'MAY' and 'OPTIONAL' in this
document are to be interpreted as described in BCP 14, RFC 2119 [3].
This is basically the same for all RFCs. Then we go to BCP 14 to find out what SHOULD means:
https://tools.ietf.org/html/bcp14
From there I quote:
Quote:1. MUST This word, or the terms "REQUIRED" or "SHALL", mean that the
definition is an absolute requirement of the specification.
....
3. SHOULD This word, or the adjective "RECOMMENDED", mean that there
may exist valid reasons in particular circumstances to ignore a
particular item, but the full implications must be understood and
carefully weighed before choosing a different course.
As you can see, SHOULD means RECOMMENDED. It is not an obligation to fulfill the requirements. I've also included item 1 (MUST) to show that the spec would definitely use MUST, and not SHOULD, if that was a requirement of the spec. MUST is only used when it is a requirement.
On the other hand, knowing that there is no obligation to set the current directory when calling a CGI script, the CGI script developer MUST make sure that the current directory is set if the task performed by the script is sensitive to current directory setting. Whoever does it differently is lazy.
