This error is also likely due to a DNS issue. You are asking ADFS directly for a token for the WAP whereas this request should also be coming from the WAP.
When accessing an application with pre-auth through WAP, you need to make sure that from the client's perspective:
- the FQDN of the app is pointing to the WAP IP address (or load balancer in the front of it) (seems to be ok now)
AND
- the FQDN of the ADFS farm is also pointing to the WAP IP address (or load balancer in the front of it)
You cannot access an application published through WAP internally using ADFS pre-authentication if you don't also use WAP for the ADFS proxy part. So it is important to set your split brain DNS correctly. Not sure if I am clear... Let me know if that makes any sense :)