I will try to reword this as best as I can. I created a virtual machine to serve as a loadtest server with RHEL. If a user requested access to this server to run a loadtest, his workstation ip would be added to the iptables so that he would have access from his Windows Workstation via ssh. It was decided that instead of editing the iptables file and then restarting services with service iptables restart, a script would be written to add a users workstation each time a user wanted to run a loadtest on this server. In addition, a seperate script would be written to remove a users workstation ip from iptables without restarting services. I suppose my main question is how do you add a rule in iptables and have it take effect without running service iptables restart ? Same question for removing a rule in iptables. Is there a few commands I can run for this or does a script need to be written ?
This is what I have so far to add a users workstation: iptables -I INPUT 1 -p tcp -s xxx.xxx.xx.xxx --dport 22 -m comment --comment "Test for pvaldez" -j ACCEPT
service iptables reload
? – Christopher May 29 '14 at 23:47