Hello all,

Here is my problem in detail,

I have to get data from remote server to local server. currently i am working on local server trying to connect to the remote server through php script. but rempte server is blocked due to security reasons.

I am the admin for the database in remote server and admin in local server too. But I could not unblock the firewall.

I am asked to make a hole to the remote server so that I can pull the data from it through my local machine.

I tried possible stuff like
1) Add a port in remote machine to give access to local server to fecth. ( group policy denied)
2) I tried
netsh firewall set icmpsetting type =All mode =Enable in remote server command prompt and the reply was ok.
but i tried to connect there is no effect

PS. Remoter server is windows machine
local server is linux machine

any help is appreciated

Thanks
manor

Dani AI

Generated

Practical, step‑by‑step addendum for and anyone else troubleshooting a Windows Server 2003 host that must accept connections from a Linux/PHP client.

Start by identifying the protocol and testing connectivity from the Linux box (this proves whether the problem is network/firewall or application-level). Example checks from the Linux shell:

telnet REMOTE_IP PORT
nc -zv REMOTE_IP PORT
# if the service is HTTP(S):
curl -I http://REMOTE_HOST/path

If the TCP connect times out, the firewall (server or perimeter) is the likely culprit. If the connection is refused, the service may not be listening on that interface/port.

If local edits are blocked, Group Policy is often the reason on domain-joined servers: firewall exceptions are normally applied centrally and must be changed at the DC (or via an appropriate GPO) rather than only on the local machine. When local edits are permitted, a safe approach is to add a port/program exception and scope it to the Linux host IP so only that source can connect. The old Server 2003 netsh “firewall” context supports adding port openings and scoping by address; newer Windows use the advfirewall context (mapping shown in Microsoft documentation). Example (Server 2003 syntax):

netsh firewall add portopening protocol=TCP port=3306 name="MySQLForLinux" mode=ENABLE scope=CUSTOM addresses=198.51.100.10

(cnblogs.com)

Verification and logs: list current port exceptions and firewall state on the server, and inspect the Windows firewall log (default path shown below) to see dropped packets.

netsh firewall show portopening
netsh firewall show state
# Windows Firewall log:
%windir%\system32\logfiles\firewall\pfirewall.log

(support.quest.com)

Notes and cautions: ’s remark about SMB only applies if file‑sharing is the transport; it is not a universal solution for HTTP/DB access. ’s suggestion to “edit database security code” is not a valid way to change a host firewall and would be unsafe. Best practices: open only the minimal port, restrict scope to the Linux host IP, prefer an application‑layer HTTPS/API or a VPN if firewall changes are restricted, and if Group Policy is enforcing settings, make the change in the GPO targeted to that server/OU so it persists and remains auditable.

Recommended Answers

All 2 Replies

look into the linux machine, are you running smb?
that is how you communicate with windows servers
perhaps re-post in the linux section

on your remote server go to the data base,
-on standard menu,
-go to tools
-click edit source code you will see the security code delete it then the fire wall will unblock.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.