I've been told my scipts would be insecure, and to fix that.
Figured i might rethink some parts of my coding style, meanwhile i tried to write an additional catcher.
I came up with this:
My 'test' result seemed good, i guess - but since i dont know much about these kind of things, i'm not sure if its even applicable.
As i am completely inexperienced with the topic of 'code injection' - or how to protect a script from such - i'm quite happy with the above code.
Though, the "$(hostname)" didnt raise an issue, but i guess that is something one cannot catch on that level.
Is this code snippet 'usable'?
Any thoughts / suggestions / advice / improvements?
Last edited by sea; 07-16-2015 at 02:53 AM..
Reason: changed code
Hi all,
Need some help in the following code. (Running this code at cygwin in windows vista)
cat /home/ebanpan/Input_Logs/*.log > /home/ebanpan/Input_Logs/input.log
sed '/^Total/d;/^Bye/d;/^Output has been logged/d' /home/ebanpan/Input_Logs/input.log > /home/ebanpan/output.log
this code... (6 Replies)
Im needing to create a postinst script for a debian package. I need it to search for this line of script in a plist file located at /folder/folder/folder/folder/folder/file.plist
<key>TESTKEYLINE</key>
<true/>
and after it create a new line and insert this code
<key>KEYNAME</key>... (0 Replies)
First let me explain the scenario
I have tywo files as usual
file1.txt (it has n rows and 8 columns)
$1 $2 $3 $4 $5 $6 $7 $8
Code:
1234567|iufgt|iuoy|iout|white |black |red |90879
1234567|iufgt|iuoy|iout|green |pink |blue |90879... (3 Replies)
Hi guys,
Those who work with Background Oriented Schlieren (BOS) might wonder how to create image pairs suitable for a PIV image processing software.
Here is the code :
#!/bin/bash
# This is a program to read *.jpg files and save them in pairs for postprocessing
nfiles=`ls -1 bild*... (0 Replies)
Hi, I have a very large, very old FORTRAN code that I work with. The code is quite messy and I was wondering if I can speed up execution time by finding subroutines that code execution spends the most time in. Is there any kind of software I can use to see where the code spends most of the... (1 Reply)
Hi:
I want to secure (prevent Ctrol+C, or Ctrol+Z, or any kind of aborting) this ksh script:
#!/usr/bin/ksh
clear
echo
print "CSIA RBAC -- CONFIGURACION --"
echo
print "1) Habilitar/Desabilitar RBAC en el sistema"
print "2) Configurar comandos privados"
print "6) Salir"
echo... (5 Replies)
I am using shell script to do secure ftp. I have done key file setup to do password less authentication. Following are the FTP Details:
FTP Client has Sun SSH.
FTP Server has F-Secure.
I am using SCP Command to do secure copy files. When I am doing this, I am getting the foll error
scp:... (2 Replies)
Hi,
I am trying to use sftp in a ksh - Shell script, but not even a simple script like this returns not output:
sftp username@remotehost <<END
ls
END
If I do something like this:
sftp username@remotehost <<END | tee logfile
ls
END
I get this error message:
Warning: tcgetattr... (1 Reply)