Posted: Mon Apr 17, 2006 11:10 am Post subject: Having a few problems.
I am new to the system and was able to install 2 games and 1 server of each.
1.) I just can't connect via ftp by my user name or as the user I gave permissions to. I have given access to them as well enabled the ftp, I even made sure apf conf has ports 2121-2800 open as I saw in another post. I am running a linux box as well if that is any help.
2.) Also I am getting errors on copying a server.
3.) I create a subdomain and cant seem to be able to login with the subdomain login and password or even the account I used to in the main domain to create the subdomain (hope that makes sense). If anyone can help me out please do.
Can you try logging in with Internet Explorer again?
I can login to a few of our subdomains fine with IE and Firefox.
What errors do you get when copying a server, and what server are you trying to copy? Please provide me a link to its overview page.
Quote:
1.) I just can't connect via ftp by my user name or as the user I gave permissions to. I have given access to them as well enabled the ftp, I even made sure apf conf has ports 2121-2800 open as I saw in another post. I am running a linux box as well if that is any help.
What error do you get when connecting? Make sure you have Passive mode FTP enabled in your client, not active.
to log in to a subdomain, you use the login details of the parent domain, you dont use the details you provided when creating the sub-domain as those are intended for the gamcreate client.
Well i went to the subdomain and got this error about Server Error in '/admin' Application Stream does not support writing. I will get back on the other stuff in a second as I am getting another error that I didnt before with ftp.
I would attempt to go on as now i can login to my domain or subdomain but now it says my host is down and it isnt, I have a dod source server going and its active now. I even logged into ssh and tried starting the gamecreate daemon again but still shows as offline on gamecreate.com. So i am assuming there is something wrong with the client? If so that may be whats wrong with the ftp problem as well?
ok now the host is up and if anyone has any idea for the ports for linux please let me know. maybe andrew knows.
Oh this is the messages from ftp client trying to connect to server.
Code:
Resolving host name "216.180.224.178"
Connecting to 216.180.224.178 Port: 2121
Connected to 216.180.224.178.
220 You will be disconnected after 1800 seconds of inactivity.
USER TCooper
331 User TCooper OK. Password required.
PASS (hidden)
230-Attempting authentication
230 OK. Current directory is /fraggersforever-srcds
SYST
215 UNIX Type: L8
FEAT
500 Unknown command.
TYPE I
200 TYPE is now 8-bit binary
REST 0
350 Restarting at 0. Send STOR or RETR to initiate transfer.
PWD
257 "/fraggersforever-srcds"
TYPE A
200 TYPE is now ASCII
PASV
227 Passive mode OK (216,180,224,178,140,17)
Opening data connection to 216.180.224.178 Port: 35857
LIST -aL
A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because connected host has failed to respond.
Timeout (40s).
Found this after a brief search on google. Make sure you change the 21 and 22 ports to the numbers you need.
Quote:
========================
SHELL SCRIPT
=========================
This should make your box pretty secure.
It provides www,https,ftp,ssh access from OUTPUT,FORWARD.
Detect portscans,SYN floods, block them,
Make all your ports "STEALTHED"
dont reply to icmp's etc.
Make sure you modify to suite your needs.
see commentouted lines for more.
MAKE SURE YOUR RULES ARE APPLIED IN "INPUT RULE" "OUTPUT RULE" "FORWARD RULE" which is located end of the script.
#!/bin/sh
############################
# IPTABLES SCRIPT #
# by Taka John Brunkhorst #
# Feel Free to Copyleft #
############################
#Basic Config
#where your iptables is
IPTABLES=/sbin/iptables
#your EXTERNAL Network interface.
EXT=eth0
#your INTERNAL Network interface.
INT=eth1
#YOUR DNS SERVER on /etc/resolv.conf
DNS1=xxx.xxx.xxx.xxx
#YOUR DNS SERVER on /etc/resolv.conf
DNS2=xxx.xxx.xxx.xxx
#Flushing and cleaning old rules.
$IPTABLES -F
$IPTABLES -X
#Setting Everything to DROP.
#note: Setting OUTPUT or FORWARD are not friendly for network games which uses ramdom ports.
$IPTABLES -P INPUT DROP
$IPTABLES -P OUTPUT DROP
$IPTABLES -P FORWARD DROP
#NAT,To enable,comment out line below.
#$IPTABLES -t nat -A POSTROUTING -o $EXT -j MASQUERADE
#IPFORWARDING, To enable, comment out line below.
#$IPTABLES -t nat -A PREROUTING -i $EXT -p tcp --dport 10535 -j DNAT --to-destination 192.168.0.251:10535
#Uncomment below to allow ipforwarding
#echo "1" > /proc/sys/net/ipv4/ip_forward
##Starting Define process.###############
##To enable these, Dont forget to modify "INPUT RULE" "OUTPUT RULE" "FORWARD RULE" at bottom of the script!###
#Allow ESTABLISHED connections
$IPTABLES -N allowed-connection
$IPTABLES -F allowed-connection
$IPTABLES -A allowed-connection -p tcp -m state --state ESTABLISHED,RELATED -j ACCEPT
$IPTABLES -A allowed-connection -p udp -m state --state ESTABLISHED,RELATED -j ACCEPT
#ALLOW INCOMING SSHD REQUESTS.
$IPTABLES -N allow-ssh-input
$IPTABLES -F allow-ssh-input
$IPTABLES -A allow-ssh-input -m limit --limit 1/second -p tcp --tcp-flags ALL RST --dport 22 -j ACCEPT
$IPTABLES -A allow-ssh-input -m limit --limit 1/second -p tcp --tcp-flags ALL FIN --dport 22 -j ACCEPT
$IPTABLES -A allow-ssh-input -m limit --limit 1/second -p tcp --tcp-flags ALL SYN --dport 22 -j ACCEPT
$IPTABLES -A allow-ssh-input -m state --state ESTABLISHED,RELATED -p tcp --dport 22 -j ACCEPT
#ALLOW INCOMING FTPD REQUESTS.
#$IPTABLES -N allow-ftp-input
#$IPTABLES -F allow-ftp-input
#$IPTABLES -A allow-ftp-input -m limit --limit 1/second -p tcp --tcp-flags ALL RST --dport 21 -j ACCEPT
#$IPTABLES -A allow-ftp-input -m limit --limit 1/second -p tcp --tcp-flags ALL FIN --dport 21 -j ACCEPT
#$IPTABLES -A allow-ftp-input -m limit --limit 1/second -p tcp --tcp-flags ALL SYN --dport 21 -j ACCEPT
#$IPTABLES -A allow-ftp-input -m state --state ESTABLISHED,RELATED -p tcp --dport 21 -j ACCEPT
#LOG and DROP Bad flags, block portscans, SYN floods. etc.
$IPTABLES -N bad-flags
$IPTABLES -F bad-flags
$IPTABLES -A bad-flags -p tcp --tcp-flags ALL FIN,URG,PSH -m limit --limit 3/minute -j LOG --log-level alert --log-prefix "NMAP-XMA
S:"
$IPTABLES -A bad-flags -p tcp --tcp-flags ALL FIN,URG,PSH -j DROP
$IPTABLES -A bad-flags -p tcp --tcp-flags ALL ALL -m limit --limit 3/minute -j LOG --log-level 1 --log-prefix "XMAS:"
$IPTABLES -A bad-flags -p tcp --tcp-flags ALL ALL -j DROP
$IPTABLES -A bad-flags -p tcp --tcp-flags ALL SYN,RST,ACK,FIN,URG -m limit --limit 3/minute -j LOG --log-level 1 --log-prefix "XMAS
-PSH:"
$IPTABLES -A bad-flags -p tcp --tcp-flags ALL SYN,RST,ACK,FIN,URG -j DROP
$IPTABLES -A bad-flags -p tcp --tcp-flags ALL NONE -m limit --limit 3/minute -j LOG --log-level 1 --log-prefix "NULL_SCAN:"
$IPTABLES -A bad-flags -p tcp --tcp-flags ALL NONE -j DROP
$IPTABLES -A bad-flags -p tcp --tcp-flags SYN,RST SYN,RST -m limit --limit 3/minute -j LOG --log-level 5 --log-prefix "SYN/RST:"
$IPTABLES -A bad-flags -p tcp --tcp-flags SYN,RST SYN,RST -j DROP
$IPTABLES -A bad-flags -p tcp --tcp-flags SYN,FIN SYN,FIN -m limit --limit 3/minute -j LOG --log-level 5 --log-prefix "SYN/FIN:"
#BLOCK OS Fingerprint Detection
$IPTABLES -N os-fingerprint
$IPTABLES -F os-fingerprint
$IPTABLES -A os-fingerprint -p tcp --dport 0 -j DROP
$IPTABLES -A os-fingerprint -p udp --dport 0 -j DROP
$IPTABLES -A os-fingerprint -p tcp --sport 0 -j DROP
$IPTABLES -A os-fingerprint -p udp --sport 0 -j DROP
$IPTABLES -A os-fingerprint -p icmp --icmp-type address-mask-request -j DROP
$IPTABLES -A os-fingerprint -p icmp --icmp-type address-mask-reply -j DROP
#DROP INVALID PACKETS
$IPTABLES -N invalid-packets
$IPTABLES -F invalid-packets
$IPTABLES -A invalid-packets -m state --state INVALID -j DROP
#BAD PORTS,TROJAN,BACKDOOR PORTS
$IPTABLES -N bad-ports
$IPTABLES -F bad-ports
$IPTABLES -A bad-ports -p tcp -m multiport --dport 3049,1999,4329,1,2,13,98,111,901,902 -j DROP
$IPTABLES -A bad-ports -p udp -m multiport --dport 3049,1999,4329,1,2,13,98,111,901,902 -j DROP
$IPTABLES -A bad-ports -p tcp --dport 12345 -j DROP
$IPTABLES -A bad-ports -p udp --dport 12345 -j DROP
$IPTABLES -A bad-ports -p tcp --dport 1524 -j DROP
$IPTABLES -A bad-ports -p udp --dport 1524 -j DROP
$IPTABLES -A bad-ports -p tcp --dport 2049 -j DROP
$IPTABLES -A bad-ports -p udp --dport 2049 -j DROP
$IPTABLES -A bad-ports -p tcp --dport 27444 -j DROP
$IPTABLES -A bad-ports -p udp --dport 27444 -j DROP
$IPTABLES -A bad-ports -p tcp --dport 31335 -j DROP
$IPTABLES -A bad-ports -p udp --dport 31335 -j DROP
$IPTABLES -A bad-ports -p tcp --dport 27665 -j DROP
$IPTABLES -A bad-ports -p udp --dport 27665 -j DROP
$IPTABLES -A bad-ports -p tcp --dport 31337 -j DROP
$IPTABLES -A bad-ports -p udp --dport 31337 -j DROP
$IPTABLES -A bad-ports -p tcp --dport 65535 -j DROP
$IPTABLES -A bad-ports -p udp --dport 65535 -j DROP
#DHCPD: Uncomment below if you are running DHCPD(SERVER)
#$IPTABLES -A INPUT -i $INT -p udp --dport 67:68 -j ACCEPT
#Uncomment below to ALLOW samba server.
#$IPTABLES -A INPUT -j allow-samba-input
#Uncomment below to ALLOW SSH server.
#$IPTABLES -A INPUT -j allow-ssh-input
#Uncomment below to ALLOW server.
#$IPTABLES -A INPUT -j allow-ftp-input
$IPTABLES -A INPUT -j invalid-packets
$IPTABLES -A INPUT -j bad-flags
$IPTABLES -A INPUT -j os-fingerprint
$IPTABLES -A INPUT -j bad-ports
$IPTABLES -A INPUT -i lo -j ACCEPT
#Always allow "allowed-connection" last!
$IPTABLES -A INPUT -j allowed-connection
####OUTPUT RULE####
#Packets going out from your box.
#ALLOW OUTGOING FTP CONNECTIONS
$IPTABLES -A OUTPUT -j allow-ftp-output
#ALLOW OUTGOING SSH CONNECTIONS
$IPTABLES -A OUTPUT -j allow-ssh-output
#ALLOW OUTGOING HTTP.HTTPS CONNECTIONS
$IPTABLES -A OUTPUT -j allow-www-output
#ALLOW OUTGOING DNS REQUEST
$IPTABLES -A OUTPUT -j allow-dns-output
#Uncomment below to ALLOW Outgoing DHCPC requests(DHCPCD)
#$IPTABLES -A OUTPUT -o $INT -p udp --dport 67:68 -j ACCEPT
$IPTABLES -A OUTPUT -j invalid-packets
$IPTABLES -A OUTPUT -j bad-flags
$IPTABLES -A OUTPUT -j os-fingerprint
$IPTABLES -A OUTPUT -j bad-ports
$IPTABLES -A OUTPUT -o lo -j ACCEPT
$IPTABLES -A OUTPUT -j allowed-connection
####FORWARD RULE####
#packets coming from NAT Clients.
#ALLOW OUTGOING FTP CONNECTIONS
$IPTABLES -A FORWARD -j allow-ftp-output
#ALLOW OUTGOING HTTP.HTTPS CONNECTIONS
$IPTABLES -A FORWARD -j allow-www-output
#ALLOW OUTGOING DNS REQUEST
$IPTABLES -A FORWARD -j allow-dns-output
$IPTABLES -A FORWARD -j bad-flags
$IPTABLES -A FORWARD -j invalid-packets
$IPTABLES -A FORWARD -j os-fingerprint
$IPTABLES -A FORWARD -j bad-ports
$IPTABLES -A FORWARD -o lo -j ACCEPT
$IPTABLES -A FORWARD -j allowed-connection
MAKE SURE YOUR RULES ARE APPLIED IN "INPUT RULE" "OUTPUT RULE" "FORWARD RULE" which is located end of the script.
now, sh iptables.sh(or whatever ur script name)
type
# iptables -L
to check your rules are applied too.
your ports should appear "BLOCKED".
even you allow ssh-input, your ports should appear "BLOCKED" too. this will make your ssh more free from ssh worms.
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum