indy 10, http proxy tunneling tcp server and client, delphi - delphi

I'm using delphi xe4 with indy10 component. My software use Tidtcpclient and tidtcpserver and works perfectly on my local network and out of my network but with port forwarding or without firewall and this is my problem because i want to run my application without portfroward my router or firewall. I think that the best way to solve this problem when i need my software out of my network is to build a http tunnel that work with port 80 that isn't blocked and reconvert the original port tcp.
i tried to search on google and i found some component of indy that can do what i need(for example idproxyserver,idconnectthroughproxy...), but i have no idea how i can do.
I need to know how setup both side client and server. Thanks in advance.

Related

Changing MQTT default port to 443

I have created a mobile application which uses secure MQTT (8883) for communication, however it looks like port 8883 is blocked by many ISP and networks.
I had read some blogs which recommend using 443 in such cases, however I am not sure if that really would solve the issue. What are the disadvantages in changing the default Secure MQTT port (8883) to 443. Can someone share their feedback in using port 443 for MQTT ?
Note: I am using EMQ MQTT (emqtt) broker with Paho MQTT client.
The list of recognised ports are there to help ensure that you can run multiple services in their default configuration on a machine without them clashing, as a rule they do not actually effect how the service runs.
With some very well used protocols (e.g. HTTP and HTTPS) network administrators may make assumptions about.
Just moving the port for native MQTT (with TLS) from 8883 to 443 to get round port blocking by networks(*) probably won't actually solve the problem. This is because the types of network that deploy these types of firewall settings also tend to conduct transparent proxying.
If you want a solution that will work even in the worst of cases then running MQTT over Secure Websockets (which is bootstrapped from HTTPS) is probably your best bet. Most of the Paho client library implementations (you don't say which you are using so can say for sure) support both native MQTT and MQTT over Websockets these days and can be given a list of broker URIs so once the broker is set up to support both you can try to connect via native MQTT then fall back to MQTT over Websockets if the connection fails.

Socket connection with different ports

I'm trying to run a socket connection from my iOS app to a bespoke server.
The iOS communicates via UDP to the server on port 12345. The request needs to come from socket 54321 on the device.
How do I open up a socket connection on iOS that communicates to a server on one port but listens via a different port.
I have followed the example on:
https://www.raywenderlich.com/3932/networking-tutorial-for-ios-how-to-create-a-socket-based-iphone-app-and-server
But this does not cover the local port
I have also looked at the documentation on https://developer.apple.com/library/ios/documentation/NetworkingInternet/Conceptual/NetworkingTopics/Articles/UsingSocketsandSocketStreams.html but I am finding it unclear due to my limited knowledge of socket connections.
I am currently attempting to use https://github.com/robbiehanson/CocoaAsyncSocket/wiki/Reference_GCDAsyncSocket
But I don't seem to be able to control the local port.
Thanks in advance
Normally you don't care about the sending socket, but when you create your AsyncUDPSocket you can use bindToPort: to set its port. Then use sendData:toHost:port:timeout:tag: to send the data

Allow CRM 2011 to access from external server

I have set up a CRM 2011 in a vmware under port 5555. I can access the CRM system fine locally. However, when I tried accessing from my host machine I got IE cannot display webpage error. I can access IIS port 80 though. I have added Inbound Rule to TCP port 5555 on my Windows Server 2008 R2 CRM server. Anything else I have to do?
Are you using anything such as no-ip, dyndns?
You have to make sure your router is mapped to route the port: 5555 to your server Ip, is your internet with static IP?
Hope that helps.
Renato
This is an old post however might help someone...
You need to allow port 5555 on your VPC (VMWare)
Go to Firewall settings and add exception for this port. Once done you should be able to access CRM externally.
Below is a detailed blog about it
http://rokhri.com/blog/crm-how-to-access-crm-externally-installed-on-vpc/

Testing both INDY TCP Client and Server in same machine delphi

I am building a basic client server application in delphi indy 10 ;
I have set sever app with local ip and a specific port, and i set client with public
IP to client host when i am testing the application the following error i got
here
I am testing both client and server app in same machine (as i had no other option),will this cause error.
You can absolutely run a TCP client and server on the same computer.
Only one application can listen on a given port at a time, but (virtually) any number of clients can connect to that server, even from the same machine.
Did you find your router settings from the previous question?

How to create a telnet connection in Delphi applications

I want to create a telnet connection in Delphi that will allow me to connect to the command prompt on my computer.
If you want a telnet server, Windows XP and newer comes with a telnet service that just needs to be enable and started via the service control manager. It is disabled by default when windows is installed. I recommend against writing your own telnet server unless you really know what you are doing because you are likely to create a lot of security issues.

Resources