find a location for property in a new city

Thursday, 6 August 2015

Outbound IP address from Azure WebJobs or WebSite

I need to find the outbound IP address of an Azure Website so that I can whitelist this IP address in a service I wish to call. However there are concerns with this practice as I will explain.

Azure WebJobs are completely awesome and they should be used more. I have project however that I am using to pre-process a large amount of data. As part of this process, my Web Job will need to call a third party web service that operates an IP whitelist. So to call it successfully I need to find the IP address of my Azure WebJob.

That is simple enough, I confirmed the IP address using two sources, one is a given list of IP's as documented by Microsoft. Details on how to find yours are here: Azure Outbound IP restrictions. I also wrote a little code to make sure this matches from a WebJob like so:

public async static Task ProcessQueueMessage(
    [QueueTrigger("iptest")] string message,
    TextWriter log)
{
    using (var client = new HttpClient())
    {
        var response = await client.GetAsync("http://ip.appspot.com/");
        var ip = await response.Content.ReadAsStringAsync();
        await log.WriteAsync(ip);
    }
}

Popping something in the "iptest" queue kicked off the job and checking the logs confirmed the WebJobs are in fact consistent with the IP ranges documented.

There is a problem however, if you read that link you will discover that although it is roughly static it is not unique. You will share your outbound IP with other users of Azure WebSites that are hosted in the same region as you and the same scale unit as you. What is a scale unit? Who cares but there are 15 of them in the North Europe data centre for example so not a lot. Now how secure do you think IP whitelisting a shared IP is? Not very!

Workaround

Don't give up hope! The work arounds I can see are to ask the service provider to not rely on only IP whitelisting, have another form of authentication, an API key over SSL would work for example. Have it as well as IP Whitelisting if it makes them happy.

If they can't be controlled you can do your own magic. There are proxy providers out there that will provide your calls with a unique static IP address. Try QuotaGuard. Or make your own - if you already have a Cloud Service running in Azure you can proxy the service via that as they can have static and unique outbound IP addresses.

Follow britishdev on Twitter

44 comments:

  1. Thanks a lot for this nice and well maintained website. I have also bookmarked this website. Now get the most affordable mats in London from rubbergymmatsuk.co.uk

    ReplyDelete
  2. Thank you for taking the time to provide us with your valuable information. We strive to provide our candidates with excellent care and we take your comments to heart.As always, we appreciate your confidence and trust in us.


    SAP Training in Chennai

    ReplyDelete

  3. Thanks for posting this useful content, Good to know about new things here, Let me share this, . Hadoop training in pune

    ReplyDelete
  4. That the development team for each company all the theoretical and practical knowledge of PHP web development work. Houston Website Development

    ReplyDelete
  5. Very helpful post.Thanks for your great information! Keep sharing.
    erp in chennai | erp software providers in chennai

    ReplyDelete
  6. Nice Blog.Thank you for Sharing. We are leading erp software software solution providers in chennai. For more details call +91 9677025199. erp software in chennai | erp providers in chennai | online events registration

    ReplyDelete
  7. The thing is each computer connected to the World Wide Web has an IP address which is given by the Internet Service Provider. Hide your IP

    ReplyDelete
  8. Are you confident that your child's teacher is doing everything necessary to assure academic success? Or do you blame public education for your child's failings? Think again! Find out why even under the guidance of the most competent teacher, your child's best chances for success rely on you.http://www.careerpanth.xyz/

    ReplyDelete
  9. Its really good information, i like your blog post. Thanks for sharing

    supersmashflash2s.com

    ReplyDelete
  10. I like your all post. You have done really good work. Thank you for the information you provide, it helped me a lot. I hope to have many more entries or so from you.
    Very interesting blog.
    minecraft2.com.br

    ReplyDelete
  11. Every good is always in my sight, and if I know how to choose fun or not is the new thing to say. Come with unblocked, abcya or titanfall or xbox one. have fun.
    unblocked sites | unblocked | titanfall

    ReplyDelete
  12. There ought to be a passage to create addresses for the accompanying sorts of recipient objects: gatherings, contacts, open envelopes and clientscheck myip

    ReplyDelete
  13. Absolutely epigrammatic. Everything is communicated so smoothly and with no defect.
    web consultant

    ReplyDelete
  14. thank You for Sharing Happy Wheel game with us ..!!!

    Happy wheels School Trip is best game for Kid i want to download latest version of Happy wheel game 
    Total Jerkface Happy Wheel

    ReplyDelete
  15. Internet online marketing is quietly experiencing a paradigm shift. Thanks to the recession, many creative marketers is forced to find more no and low cost ways to promote their business, products and services to customers. While many online businesses customer base shrinks, ad marketing budgets fade and online market share dwindles, many are forced to find creative ways to promote or perish. internet marketing pricing

    ReplyDelete
  16. AvriqPrinter RepairPrinter InstalltionWifi trouble shooting
    Software InstalltionThis is really a pleasant and useful, containing all data furthermore greatly affect the new innovation. Much obliged for sharing it,
    Virus removal

    ReplyDelete
  17. Item or specialist co-ops on the web, utilize the accessible data to tout unconscious hard actualities. Windows USA Offers Tips For Windows

    ReplyDelete
  18. This is a great article thanks for sharing this informative information. I will visit your blog regularly for some latest post. I will visit your blog regularly for Some latest post. website build

    ReplyDelete
  19. This is the type of information I’ve long been trying to find. Thank you for writing this information. website build

    ReplyDelete
  20. This is for open VPN and Tunnelblick programming customers. Normally Open VPN makes a 128 piece scrambled information channel and a 256 piece encoded control channel. http://whatsmyrouterip.com/

    ReplyDelete
  21. You should mainly superior together with well-performing material, which means that see it:
    mason soiza

    ReplyDelete
  22. Octal Digital is a leading web development company providing web design at affordable prices. They provide android app development in houston, wordpress web design, magento web development, drupal development and SEO services.

    ReplyDelete
  23. This is my first time i visit here and I found so many interesting stuff in your blog especially it's discussion, thank you. Home Security Systems

    ReplyDelete
  24. Motifz Designer Lawn. 1, 2 & 3 Piece Unstitched Premium Embroidered Lawn 2019, Premium Lawn, Lawn 2019, Best lawn collection, Motifz, Best Lawn in Pakistan, Shipping worldwide. Stitching option available.

    ReplyDelete
  25. Buy Premium lawn Online for Women's at best prices available at Motifz. ✓ Latest Fashion, ✓ Trendy Designs ➤ Shop Now!

    ReplyDelete
  26. This blog post is really great; the standard stuff of the post is genuinely amazing.
    custom business security cameras

    ReplyDelete
  27. Keep up the good work; I read few posts on this website, including I consider that your blog is fascinating and has sets of the fantastic piece of information. Thanks for your valuable efforts. https://192-168-i-i.com/

    ReplyDelete
  28. A pesticide company east of Riyadh and Dammam
    • The company sends a specialized Filipino team, spraying the pesticide with the latest advanced equipment.
    افضل شركة مكافحة حشرات
    شركة مكافحة النمل الابيض بالاحساء
    شركة مكافحة حشرات بالاحساء
    شركة رش مبيدات بالاحساء

    ReplyDelete
  29. Find the best Lawn Mowers price! Lawn Mowers for sale in United State. OLX United State offers online local classified ads for husqvarna self propelled lawn mower. Post your classified ad for free in various ...

    ReplyDelete


  30. 192.168.0.1

    192.168.1.1

    router login
    Positive site, where did u come up with the information on this posting?I have read a few of the articles on your website now,

    ReplyDelete
  31. I learn some new stuff from it too, thanks for sharing your information. freelance web designer

    ReplyDelete