Subject: [Info-WASD] Yet another 'conan' postscript
From: [email-masked]
To: [email-masked]
Date: Wed, 26 Nov 2025 14:48:18 +1030

There are various methods for eliminating a nuisance script.

1) remove its WASD_CONFIG_MAP (404 it)
2) remap it to a flat file message
3) modify the script to provide a message

There were various mappings, both implicit and explicitly in use by crawlers

  /help
  /conan
  /cgi-bin/conan
  /cgiplus-bin/conan

all ending up at the CGI-BIN:[000000]CONAN.COM wrapper, typically

┊EISNER$ type cgi_bin:conan.com_
┊$ CONAN == "$CGI-BIN:[000000]CONAN"
┊$ CONAN

so modifying that procedure seemed the most sure.  At first a vanilla CGI
wrapper was created (effectively the first if-endif block).  This resulted in
a script runup+response+rundown expense for each invocation.  Eventually the
little demon on my left shoulder whispered about the overhead involved and a
CGIplus version evolved; runup+response+response+response+...rundown.  Not
sure about the exact relative overheads.  At least the demon has gone quiet.

For reference:

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
EISNER$ type cgi_bin:conan.com
$ if f$trnlnm("CGIPLUSEOF") .eqs. ""
$ then
$!  (standard CGI)
$   type sys$input
status: 503
content-type: text/html

<div style="font-size:1.5em;">
Due to <i>content scraper</i> <b>abuse</b> the <b>help/conan</b> app
has been disabled.
</div>
$   exit
$ endif
$!(CGI plus)
$ say = "write sys$output"
$ count = 0
$ first = f$time()
$ open /read CgiPlusIn CGIPLUSIN
$!
$ requestLoop:
$!
$!   (block waiting for request, this initial read is always discardable)
$    read CgiPlusIn /end=endRequestLoop line
$    count = count + 1
$!
$    type sys$input
status: 503
content-type: text/html

<div style="font-size:1.5em;">
Due to <i>content scraper</i> <b>abuse</b> the <b>help/conan</b> app
has been disabled.
</div>
$    say "<!-- ''first' : ''count' @ ''f$time()' -->"
$!
$!   (read to exhaustion the CGIplus variable stream)
$    cgiLoop:
$       read CgiPlusIn /end=endCgiLoop line
$       if line .eqs. "" then goto endCgiLoop
$       goto cgiLoop
$    endCgiLoop:
$!
$    say f$trnlnm("CGIPLUSEOF")
$    goto requestLoop
$!
$ endRequestLoop: