0

I really have a simple question (well, I think that this is a simple question though). I'm trying to limit access just to one single IP address. If I'm inspecting the IP address, the IP address has a x.x.x.x/20 prefix. Most of the examples on the internet shows me to use /32 instead. I've tried IP address with 20 as well as 32 prefixes. However, without any successful attempts I'm not able to access my AppService through my frontend application. In fact, I even tried to give access in the AppService to my location machine without making requests through my frontend app, even then it won't allow me to access my AppService?

First of all, I navigate to my AppService that is running on Azure, whereafter having clicked on the AppService I choose for 'Networking'. On this page, I'm able to click on 'Access restriction' where I can limit IP ranges/addresses.

Inbound Traffic

Here is an example of how I'm trying to accomplish this:

Access Restrictions

Hopefully I was able to provide enough information for you. Any thoughts why this would not work?

QuentinC
  • 12,311
  • 4
  • 24
  • 37
user20291437
  • 99
  • 1
  • 8

1 Answers1

1

I have configured the Single IP Address to my Azure app service which works successfully fine:

enter image description here

External IP addresses which are not specified in the access restrictions will not work to route my azure app service:

enter image description here

If there are any front-end files, that filenames should be added in the default documents sections which is in Azure Portal > App Service > Configuration > Default Documents:

enter image description here

Refer to this MS Doc for more information on default web page defining of an Azure App Service and mapping the URL path to a directory.

Pravallika KV
  • 2,415
  • 2
  • 2
  • 7
  • I'm just confused, because now I'm able to allow/disallow my computer to the appservice. However, when I try to use the website's IP address it still gives me Error 403 - Forbidden... Like I'm using a VPS to host my website, therefore I used the IP address of the VPS server. On this VPS server I have Nginx Proxy Manager running and it is redirecting requests to my website, whereafter I use the website to access the AppService (but still can't). I just don't get it... – user20291437 Nov 29 '22 at 16:19
  • Even though I did not configure 'Default documents' I'm still able to access through my own computer the AppService's default page... In fact, my AppService plan does not have 'Default documents' by the way... – user20291437 Nov 29 '22 at 16:22
  • It turns out that my VPS' IP address was somehow listed within **SORBS** and **RATS blacklists**. Therefore, when I try to 'Allow' this IP address Azure will not allow it in its App Service configuration. Although, without specifying any IP restrictions I can still reach my App Service through my VPS server. However, you cannot add something being allowed within Azure if that IP address is blacklisted somewhere... I still will accept your answer, since it provides a good basic starting point for new users like me. – user20291437 Nov 30 '22 at 21:42
  • Moreover, to solve this issue you should contact your VPS provider. In my case, they will provide a new IP address to me and in the meantime they also will try to recover initial provided IP address' state (removing from blacklists). After being cleaned, they will assign this IP address back to my VPS server and I will be able to use the initial IP address again. Another solution they suggested was either to install a new VPS server with a new IP address but then I would lose all my data which is inconvenient of course. I would go obviously with the first option. – user20291437 Nov 30 '22 at 21:47
  • I recommend to use an online service to check whether or not your IP/domain is blacklisted. You could use something like [MxToolBox](https://mxtoolbox.com/blacklists.aspx) – user20291437 Nov 30 '22 at 22:23