Intensify thinking; there must be a way!

518
width: 580
page: bsta-000518.htm
frametype: normal
ext: gif
ongtime: 1667358002
frame: bsta-000518.gif
height: 410
command: Perfect plan! When will be the next access to the server?
title: Intensify thinking; there must be a way!
timer: 83
content-type: image/gif

You continue thinking about this.
But more intensively.
And you have an idea.

One of your scripts asked the server for all files in a specific directory.
It would download the files,
check some things in their content,
perform some actions,
remove the files,
and continue.

Two very important details:
The files are downloaded to the same directory where the script is located.
The files are saved under their original names that they have on your server.

If the server contains a file
which has the same name as the script
and which happens to be a totally different new script
then the script will download it and overwrite itself.
(and probably crash)

Next time when the script is restarted
(you made a periodic task which restarts the script so in case of any problem it can continue from where it stopped)
actually, your new script will be started instead.
And this new script can make a reverse SSH connection to the server at night
(so that you in the past don't notice anything strange)
At the end the new script should overwrite itself with the original script.

"BSTA" by Balthasar Szczepański
Online interface v1.2.8 © Balthasar Szczepański; AGPL 3 license
source code

1190.bicyclesonthemoon.info