Closed. This question needs details or clarity. It is not currently accepting answers.
Want to improve this question? Add details and clarify the problem by editing this post.
Closed 9 years ago.
Improve this question
I cannot host my own server for iOS push notification because the router is limited by Admin.
I want to learn from scratch so I don't want to use Parse or quickblox. Where and how can I know which PHP hosting plan support iOS push notification? Is there any free hosting available?
From Apple, the server need to allow inbound and outbound TCP packets over port 2196. I don't think regular hosting plan will list out this information.
http://developer.apple.com/library/ios/#technotes/tn2265/_index.html#//apple_ref/doc/uid/DTS40010376-CH1-TNTAG41
When I learnt Android push notification, I can easily find a hosting plan with CURL. iOS is a bit demanding.
The port that you really need for sending push notifications is 2195. Even though the TCP packets are both inbound and outbound from your server, the connection is only outbound (you initiate the connection to Apple). Most web host providers won't have an issue with this.
Port 2196 is the feedback service, which you should implement, but it's optional. It's the same way, inbound and outbound TCP packets over port 2196, but you initiate the connection.
When a device registers with your server for push notifications by sending the device token, the device initiates the connection, and you have your choice of how to send the notification to the server. If you send it via HTTP (with NSURLConnection, for instance), any basic web server will do.
I implemented Easy APNS in only a couple hours and it works fine on my shared hosting environment at Dreamhost. You just need a basic LAMP stack (Linux, Apache, MySQL, PHP) and a downloaded copy of your APNS certificates. Easy APNS is all open source, so you can see how they're doing it.
Related
Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 8 years ago.
Improve this question
How may I create a socket on my computer that could be reachable from other computers via internet, and work like a web server, maybe using WebSockets?
By the way: could my web server become visible from the Internet and how?
I know I can install a LAMP web server on my computer (my OS is Ubuntu) and use it for a local network.
I know I can use sockets to let 2 computers communicate via internet using their IP addresses (I did it in Java).
You can make your LAMP server stack accessible from the internet by forwarding ports from your external internet connection to the computer the server stack is running on. If you're doing this at home, you can usually handle port forwarding from the admin interface for your router/modem.
Alternatively, WebRTC is a newer web technology (still in the testing phase) that allows two browsers to connect to each other without the need for an intermediate web server.
Browser does not permit raw sockets.
You can not create a socket from browser, because it would be security hole.
For example you download a page from internet and script on this page opened all sockets on your computer.
Websockets it is technology on top of TCP protocol.
Using Websockets you can connect two browsers to a Websocket server and exchange information via this server.
Closed. This question is off-topic. It is not currently accepting answers.
Want to improve this question? Update the question so it's on-topic for Stack Overflow.
Closed 9 years ago.
Improve this question
I am trying to fully understand the TCP/UDP protocol before starting a network project.
Let's say I have a TCP Server. I understand that if I want someone to communicate with via Internet I need to open my listening port: the router/firewall let it pass and redirect it to me.
A TCP client is connecting to me, there is now a bound socket between the two systems. But how the server can send data to the client if this one have his port blocked:
The port is chosen dynamically, how the firewall/router know that it need to allow the data from my server, is it because I already send something to it and now knows that there is some kind of connection?
If yes, does it mean that for UDP both machines needs to unlock the port?
I don't completely understand how it works but this is what I got so far :
Server is listening on port X
Client try to connect to Server on port X (random port Y generated)
Server can now repond to Client on port Y
Port Y is maintened open thanks to TCP with keep-alive packet.
The firewall/router let it 'open' for some.. seconds ? because there was out-coming packet from his network (waiting for in-coming ?)
And that's how two UDP client can for example communicate :
http://en.wikipedia.org/wiki/UDP_hole_punching
Example with Skype :
http://www.h-online.com/security/features/How-Skype-Co-get-round-firewalls-747197.html
Please correct me if I'm wrong or something seems you not quite well.
Thanks
Edit
A NAT router therefore keeps tables of which internal computer has communicated with which external computer and which ports the two have used.
That's the trick that let the firewall "unlock" our port.
Closed. This question is off-topic. It is not currently accepting answers.
Want to improve this question? Update the question so it's on-topic for Stack Overflow.
Closed 10 years ago.
Improve this question
I am using Hmailserver as a mail server, and it is working normally for mail clients using a standard internet connection (wired or wireless).
But when using a mobile device in 3G mode, suddenly it is not possible to send emails anymore. In the mail client there is a non saying error message (such as unknown error ocurred). Is there any reason for this?
It is quite hard to say; however, e-mail usually travels over port 25 when using SMTP. Likely your 3G provider is blocking outgoing port 25 connections.
You can verify this by using telnet (a Google for "Windows telnet" will provide some Microsoft documentation) to connect to a well-known mail server (these are advertised in DNS MX records). On Windows, I believe the syntax at the command line would be: "telnet <host> 25" (for Google a valid mail-host is alt2.aspmx.l.google.com).
If your provider is blocking port 25 traffic, you will see a connection denied message. Usually ISP's prefer you connect to their SMTP server -- so that they can prevent SPAM from emanating from their network.
Closed. This question is off-topic. It is not currently accepting answers.
Want to improve this question? Update the question so it's on-topic for Stack Overflow.
Closed 9 years ago.
Improve this question
I have configured ejabberd server on localhost. I am able to connect to local host like admin#localhost, but i am not able to connect gtalk server. Some one please help me how to connect to gtalk server.
Thanks in advance,
sathi
In order for you to talk to GoogleTalk, they have to be able to talk back to you using Dialback. There are several steps you'll need to do:
Rename your server to a fully-qualified domain name. (e.g. example.com)
Open a hole in your firewall in both directions to your server on port 5269/tcp.
Add an SRV record to your DNS pointing at that firewall hole. If your domain was example.com, your SRV might have _xmpp-server._tcp.example.com pointing to 10 0 5269 myserver.example.com.
At some point in the future, you may also need an X.509 certificate for doing TLS.
I almost lost hope, but this thread was really helpful:
Short summary - disable google apps for domain, it can be the reason of getting 404 errors in ejabberd log.
Closed. This question is off-topic. It is not currently accepting answers.
Want to improve this question? Update the question so it's on-topic for Stack Overflow.
Closed 10 years ago.
Improve this question
I have a mail server in our local network that run through Kerio firewall. I open tcp 110 port, and try to get mail from Mdaemon to Gmail, but all in vain.
Thanks in advance.
I'm sure that this question's been abandoned... But, I'm waiting for a server to reboot and there's nothing better to do atm.... MDaemon's a good product that we've used for quite some time (with some headbanging, unfortunately).
TCP Port 110 is used by the POP protocol, normally (but not always) used by mail clients to read email from a mail server.
There's nothing special about how MDaemon uses POP, other than that it can be turned of for the entire server or for individual accounts.
POP isn't what's used to get mail from your MDaemon server to Gmail, though (unless you're telling your gmail account to ALSO check mail on an outside mail server). In most situations, you'll use SMTP over port 25 to exchange mail between servers. (MDaemon supports a feature called "DomainPOP" where you can use Port 110 to collect mail from another server for local distribution based on other headers, but it's not used very often.)
The question sounds like you're trying to SEND email from your local server to an account on Gmail. You'll need to have TCP port 25 open outbound through your firewall to send mail. That doesn't mean that the remote host has to accept mail from you -- but it will make the initial handshake possible.
Usually, a fully configured mail server will have a public IP address and DNS name that directs SMTP traffic to it. It's strongly reccommended that your domain DNS have an MX record that points to your mail server. Ideally, there should be a reverse DNS pointer for the mail server.
Because of all the SPAM in the world, many mail servers refuse connections from other hosts that don't have a DNS record and a reverse pointer. That's not the only reason they refuse connections, of course, but it's one.
Anyways, I expect the original user had one of three possibilities: 1) They needed SMTP open in their firewall when they opened POP instead;
2) They had POP turned off for their MDaemon account (can gmail even be configured to act as a pop client for another account?); or 3) they got blocked because of a bad dns record/pointer combination.