I have an InfoPath form that was working.
It uses the SharePoint GetUserProfileByName method to get the user’s details to populate fields on the form. The form, that was working, recently stopped working giving the error: “The following query failed: GetUserProfileByName” and words to the effect that the user is unauthorised.
Strangely enough it turns out the solution was related to a previous post here where a web service could not be accessed because the web.config dynamic value for the web service set the site back to the root site.
My form was pointing to the root site for the web service. At that level the users don’t have permissions to access the web service. They do however have it at the sub-site level. Simply pointing the web service at the sub-site made the form work again.
But what broke it? I can only contribute it to the fact that I recently turned on Kerberos authentication on the Site Collection that these forms are part of and that has somehow affected the ability of the users to connect to the web service at the root level of the collection. Go figure.