Jumoo / uSync.Complete.Issues

Public Issue tracker and roadmap for uSync.Complete
https://jumoo.co.uk/usync/complete/
2 stars 1 forks source link

IncludeHost option, so sending requests between servers doesn't have to include the host value. #148

Closed KevinJump closed 2 years ago

KevinJump commented 2 years ago

There are occasions when you can't reliably tell what the URL of the target server is going to be. (it can be set in umbraco settings, but sometimes firewalls, proxies etc mean you can't do that).

All communication in uSync.Publisher is signed and the signiture contains the URL the request is intended for including the host. So while a request might be sent to a URL when it gets there it might be diffrent, and the validation will fail.

you can override the host name used for signing a request with the baseURL property. but if for some reason you cannot use the BaseURL property. you can tell uSync not to send the host as part of the signiture.

Setting IncludeHost to false on all servers (sending and receiving) will mean that the host name is not part of the signed message (the that and query are still included just not the protocol and host)

"uSync": {
    "Publisher": {
      "Settings": {
        "IncomingEnabled": true,
        "AppId": "XXXXXXXXXXXXX",
        "AppKey": "XXXXXXXXXXXXXX",
        "IncludeHost": false
      }
    }
}