socket.error: [Errno 10013] Port forbidden access permissions

06
2014-04
  • user1494941

    When trying to use a Python script I get this error:

    socket.error: [Errno 10013] An attempt was made to access a socket in a way forbidden by its access permissions

    I put the post on Stackoverflow and I have been guided to come here and follow up with why I get the error.

    http://stackoverflow.com/questions/18370235/socket-error-sending-email-using-gmail

    As the post on stackoverflow suggests, the issue is not with Python, but my computer. I can even telnet to smtp.gmail.com

    Can anyone provide any suggestions?

    EDIT: SOLVED

    The problem was McAfee Antivirus. It was blocking the socket connection.

    From McAfee Access Protection Log

    23/08/2013 10:23:54 a.m. Blocked by port blocking rule C:\Program Files (x86)\Python26\python.exe Anti-virus Standard Protection:Prevent mass mailing worms from sending mail 74.125.25.108:25

    I disabled McAfee completely and it worked fine after that.

    Thanks

  • Answers
    Know someone who can answer? Share a link to this question via email, Google+, Twitter, or Facebook.

    Related Question

    irc - Accessing freenode without ports
  • Christian

    I'm at a computer where most ports are blocked. Is there still a way to access freenode to ask about programming questions through some webinterface?


  • Related Answers
  • foraidt

    Have you tried http://webchat.freenode.net/ ?
    From what process explorer shows, it does not look like firefox uses any IRC specific ports but HTTPS.

    For other IRC networks, you could give http://www.mibbit.com/chat/ a try. I couldn't get it to connect to freenode because mibbit seems to be explicitly blocked there.

  • Svish

    Tried any of the alternative ports?

    All freenode servers listen on ports 6665, 6666, 6667, 7000(SSL Only), 7070 (SSL Only), 8000, 8001 and 8002. -- Freenode

  • DavidSzp

    It's slightly more advanced, but if you install your own copy of the ZNC IRC bouncer (http://znc.in) or find someone else to host it for you (there are other bouncers out there as well), you can connect to the bouncer instead and it then proxies IRC traffic to you. I run znc on Linux but there is a Windows port out there too a friend has run. If you listen on port 80 or 443 you're more likely to get through, but sometimes just a non-IRC port is good enough since many places explicitly block the IRC ports Svish mentioned due to potential botnet activity (or time-wasting).

    This of course requires your own computer where you can control inbound traffic (to listen on port 80 or 443) and run znc continually. But it can do some nice things like allowing you to connect from an unlimited number of clients simultaneously, using one nickname and being in all the same channels. It can also save a buffer while you're disconnected from znc so when you connect (from any client) you get a reply of the last "x" lines (whatever you specify) and can catch up. It can also log chats, and it's great for connecting from mobile phones like the iPhone especially because of the buffer (since the iPhone would lose history every time you switched apps otherwise).

    So...a little more complex of an answer, but if you're a heavy IRC user it's probably worth the hassle of getting it set up and configured because it's quite powerful. Znc can let you connect to it in unencrypted and SSL encrypted modes depending on how you set it up (the connection to the IRC server is separate).

    If you use ZNC and an iPhone, you can compile the Colloquy plugin for ZNC and then ZNC will also let you set up Push notifications to your iPhone for mentions of your username (by default) or other watch words (configurable through messaging *colloquy on the ZNC server). This requires using the Colloquy iPhone app as well.

  • MDMarra

    A port is absolutely needed to connect to a service over the network. Without a port you cannot make a connection, it's how the TCP/IP suite of protocols work.

    One way around it is to use a web chat, since port 80 and 443 for HTTP(S) traffic will probably work, but you won't be able to use a standalone client if the appropriate ports are blocked.