Hi @Umer Rashid
There's no way to block or control access to these ports in the multitenant service.
https://learn.microsoft.com/en-us/azure/app-service/networking-features#app-service-ports
Kindly refer the thread:https://learn.microsoft.com/en-us/answers/questions/1337314/disable-ports-1221-and-8172-on-a-simple-web-app-se
Please accept as "Yes" if the answer provided is useful, so that you can help others in the community looking for remediation for similar issues.