Converting a shell script to program


 
Thread Tools Search this Thread
Top Forums Shell Programming and Scripting Converting a shell script to program
# 1  
Old 12-29-2013
RedHat Converting a shell script to program

Hi I am new in programming.

I have written a shell code, but i want to secure my code.

I have tried SHC. It is converting it to binary, but can be converted in plain text again by core dump.

I have tried to convert it in rpm by "rpmbuild -bb my.spec" option but the result is same.

Is there any idea/way by which we can protect it by getting plain text code.

How other linux commands are converted to binary ?

Last edited by Priy; 12-29-2013 at 01:48 PM.. Reason: Not posted properlly.
# 2  
Old 12-29-2013
Quote:
Originally Posted by Priy
Hi I am new in programming.

I have written a shell code, but i want to secure my code.

I have tried SHC. It is converting it to binary, but can be converted in plain text again by core dump.

I have tried to convert it in rpm by "rpmbuild -bb my.spec" option but the result is same.

Is there any idea/way by which we can protect it by getting plain text code.

How other linux commands are converted to binary ?
shell code is different from shell script.

What makes your code so secret? did you embed passwords inside?

another way. Write in C and compile.
# 3  
Old 12-30-2013
Yes, Passwords are there.

I have used dialog command in shell, I am not getting how to use dialog in c program.
# 4  
Old 12-30-2013
bring your password outside the script. Usually the way to do this is via a database that provide login mechanisms + encryption. If not, you can set up an encrypted file that stores the password. See here for more info.
This User Gave Thanks to kurumi For This Post:
# 5  
Old 12-30-2013
Hi kurumi,

Thanks for idea,
But can you give ideas/link on how to write same in c .
Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

Script Shell how's converting .html files

Hello everybody, :) I need some help with a school project that I have to create for the next week. :eek: So first, the aim of the Script is that I have a WebSite with a lot of .html / .shtml / .js / .css in one directory. That directory have few directory too but that's not so important,... (1 Reply)
Discussion started by: mariocrocop
1 Replies

2. UNIX for Beginners Questions & Answers

Converting the following batch script to Linux shell

I am currently migrating to ubuntu from my windows system. Now I am learing to convert all my batch scripts into linux shell. Although the common commands are more or less similar, but I found it difficult for the following set of commands in windows cmd: setlocal :PROMPT SET /P... (2 Replies)
Discussion started by: net.genere
2 Replies

3. Shell Programming and Scripting

Shell Script for converting file to Excel or CSV

Hi I have a dat file which has "n" number of columns. The file is delimited. The number of columns keep varying as the file is generated out of DB queries. Could you please help me in writing a script which will generate a XLS or CSV file out of the dat file. (5 Replies)
Discussion started by: Vee
5 Replies

4. UNIX for Dummies Questions & Answers

converting string to number in shell script

Hi, I am having a problem in converting a string to number so I can preform arithmetic operations. timeTot=0 timeTmp=$(cat idsOutput | grep 'Run time' | cut -c 36-39) timeTot=$ #This is line 28 echo "total RunTime=" $timeTot this is the error msg: ./ids2.sh: line 28: 0+1.35: syntax... (8 Replies)
Discussion started by: turki_00
8 Replies

5. Shell Programming and Scripting

Converting rows to columns using shell script

I have a script which converts rows to columns. file_name=$1 mailid=$2 #CREATE BACKUP OF ORIGINAL FILE #cp ${file_name}.xlsx ${file_name}_temp.xlsx #tr '\t' '|' < ${file_name}_temp.xlsx > ${file_name}_temp.csv #rm ${file_name}_temp.xlsx pivot_row=`head -1 ${file_name}` sed 1d... (3 Replies)
Discussion started by: andy538
3 Replies

6. UNIX for Advanced & Expert Users

converting rows to clumns using shell script

I have a script which converts rows to columns. file_name=$1 mailid=$2 #CREATE BACKUP OF ORIGINAL FILE #cp ${file_name}.xlsx ${file_name}_temp.xlsx #tr '\t' '|' < ${file_name}_temp.xlsx > ${file_name}_temp.csv #rm ${file_name}_temp.xlsx pivot_row=`head -1 ${file_name}` sed 1d... (0 Replies)
Discussion started by: andy538
0 Replies

7. Shell Programming and Scripting

Unix shell script converting temperatures.

:confused:Please I really need help with an assignment question. I need to write a script that will take the input from a file and convert the number from Centigrade(Celcius) to Fahrenheit or vice versa. Thank you so much. I really need it to be detailed. Please remember the input comes from a file. (1 Reply)
Discussion started by: starter101
1 Replies

8. Shell Programming and Scripting

Problem in converting number in shell script

Hi All, I am writing a shell script in which I want to convert a number like : Suppose the number is "98487657" and we have to convert it to "98000000", what I want to do is to retain first 2 digits and convert all remaining digits to "0". Number could be of any length (length... (4 Replies)
Discussion started by: amitanshu.verma
4 Replies

9. Shell Programming and Scripting

Converting Shell Script to HTML

Hi, Im new to shell scripting. My task is to convert shell script feed into html, so basically I have a lot of information in shell script and I want to convert it html. I know you can simply convert the information by hand, but is there any simpler way? Thank you Dave (3 Replies)
Discussion started by: davwel
3 Replies

10. Shell Programming and Scripting

Converting Shell script to Dos batch files

Hi friends! I am having some simple shell script files to build postgresql database and all. Now i want to convert those scripts to dos batch scripts(to run on windows XP/2000/NT) because there is no need of unix emulation for latest release of postgresql. Please somebody help me. (1 Reply)
Discussion started by: darwinkna
1 Replies
Login or Register to Ask a Question