LinuxQuestions.org
Latest LQ Deal: Linux Power User Bundle
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 12-04-2009, 02:45 AM   #1
anaigini45
Member
 
Registered: Nov 2009
Posts: 43

Rep: Reputation: 15
Problems installing firewall script


Hi,

I've created a firewall script in my management workstation and am suppose to install the script in the firewall machine which is my local server.

I'm only using one interface for the firewall as it is only to protect the server and not the whole network. The address of the interface (internal address/inside address) is 192.168.0.90. The management workstation address is 192.168.0.248.

I've already created a user(fwadmin), a group(fwadmin), and the directory /etc/fw where the firewall script should be installed and activated.

I want to use user account and not root account to manage the firewall script in the firewall machine. Does this mean that I have to login as fwadmin in the firewall machine and not root?

Now I type this command in the console of the management workstation (where the firewall script is created).

ssh fwadmin@192.168.0.90 sudo -S /etc/fw/New.fw

This is to login to the firewall machine as user fwadmin and copy and activate the firewall script(New.fw) there.

The output that I get is
id : cannot find name for group id 502.

I've already set the permissions for /etc/passwd and /etc/group as 644.

Pls help me solve this problem.

Last edited by anaigini45; 12-04-2009 at 02:48 AM.
 
Old 12-05-2009, 12:56 PM   #2
jhwilliams
Senior Member
 
Registered: Apr 2007
Location: Portland, OR
Distribution: Debian, Android, LFS
Posts: 1,168

Rep: Reputation: 210Reputation: 210Reputation: 210
Quote:
Originally Posted by anaigini45 View Post
ssh fwadmin@192.168.0.90 sudo -S /etc/fw/New.fw

This is to login to the firewall machine as user fwadmin and copy and activate the firewall script(New.fw) there.
If you're logging in as the user who presumably owns /etc/fs/New.fw, why are you using sudo at all? Also, note that your command doesn't copy anything. Read the scp(1) for that. http://www.linuxcommand.org/man_pages/scp1.html. To call the script, from a remote machine, you'll want to do something like

Code:
ssh fwadmin@192.168.0.90 ./etc/fs/New.fw
,

I'm assuming that this is a Bash script that is tested and working locally, and has the correct permissions set.

Also, you had a question about root: it, as always, can do absolutely anything, including as a subset, anything that user fwadmin can do.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
My firewall script gabsik Linux - Security 2 04-08-2006 02:19 PM
Firewall script simcox1 Linux - Security 7 11-13-2005 01:08 PM
slackware's /etc/rc.d/rc.firewall equivalent ||| firewall script startup win32sux Debian 1 03-06-2004 10:15 PM
IP TABLES Firewall Script problems... Nosram Linux - Networking 2 02-11-2004 05:22 AM
Firewall script help!!!! cirkut5732 Linux - Newbie 8 04-17-2003 07:09 PM


All times are GMT -5. The time now is 10:23 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration