Hello @Nitin Parmar-Tss consultancy ,
Welcome to Microsoft Q&A Platform. Thank you for reaching out & hope you are doing well.
I understand that you are trying to set up a FortiGate firewall virtual machine as a backend pool of your Application gateway and you've configured port 443 backend setting and listener, but you are getting unhealthy errors in the backend pool. So, you would like to know which SSL certificate needs to be generated on the FortiGate firewall end.
Root cause of your issue:
In the v2 SKU, if there's a default probe (no custom probe has been configured and associated), SNI will be set from the host name mentioned in the HTTP settings. Or, if “Pick host name from backend address” is mentioned in the HTTP settings, where the backend address pool contains a valid FQDN, this setting will be applied.
If there's a custom probe associated with the HTTP settings, SNI will be set from the host name mentioned in the custom probe configuration. Or, if Pick hostname from backend HTTP settings is selected in the custom probe, SNI will be set from the host name mentioned in the HTTP settings.
If Pick hostname from backend address is set in the HTTP settings, the backend address pool must contain a valid FQDN.
If you receive this error message, the CN of the backend certificate doesn't match the host name configured in the custom probe, or the HTTP settings if Pick hostname from backend HTTP settings is selected. If you're using a default probe, the host name will be set as 127.0.0.1. If that’s not a desired value, you should create a custom probe and associate it with the HTTP settings.
Resolution:
I see that your backend setting has Pick host name from backend target, but you've added the NIC of your VM and not the FQDN.
As mentioned above, if Pick hostname from backend address is set in the HTTP settings, the backend address pool must contain a valid FQDN. So, select the backend target type as IP address or FQDN and add a valid FQDN in the target address.
If the above is not feasible, then verify the CN (Common Name) of the certificate and enter the same in the host name field of the custom probe or in the HTTP settings (if Pick hostname from backend HTTP settings is selected).
And if the CN of your existing certificate doesn't match the desired host name for your website, you must get a certificate for that domain or enter the correct host name in the custom probe or HTTP setting configuration.
If you are using a wildcard hostname in your listener like *.trackwizz.app
, you must upload a wildcard certificate with CN like *.trackwizz.app
.
Kindly let us know if the above helps or you need further assistance on this issue.
Please "Accept the answer" if the information helped you. This will help us and others in the community as well.