Open samperrow opened 2 years ago
Hey @samperrow,
Do you have an idea how I could configure on-prem instance with strict-origin to verify if it works?
Could you check are you able consuming SharePoint API via sp-request. If it worked I guess I can manage a referrer to workaround the policy.
@koltyakov I do not know how you could configure an on-prem SP instance to test this unfortunately.. And I wasn't able to get this working with sp-request, so maybe there is no work-around that is readily available.
@samperrow in short you can do this but you need to have some middleware that changes the origin of the host header to match the target URL. For express http-proxy-middleware has this functionality in its createProxyMiddleware method.
I have tried connecting to an on-premise SP environment with those safeguards, but I haven't been able to successfully make HTTP requests via this proxy service.