Jump to content

.well-known folder with file vertification

Go to solution Solved by paul2009,

Recommended Posts

Posted

In order to do microsoft domain verification, i need to upload a json file to be served at https://<domain>/.well-known/microsoft-identity-association.json

Tough it turns out, . character can not be used for link "slugs".

 

It is possible to host this file on my domain in anyway? I do my DNS management on aws, but i don't know if i can route from DNS to another server by url path.

 

 

  • 3 months later...
Posted

Hey,

I'm looking to see if something is possible with SquareSpace before we agree to migrate over. 

We work with several partners who insist on doing validations with a file on the root domain rather than the preferred TXT record validation on DNS. For this we have to put a file in a folder at the root of the website in a folder called /.well-known. The file for example would be called test.devicemenagement and it would contain a text string for validation. 

This would then enable various partners to validate us on www.domain.com/.well-known/test.devicemanagemant

To further confuse this we need to add in a MIME type or contact to make sure the file extension of *.devicemanagement is downloaded as a JSON file.

Does anyone have any ideas of this is possible with Squarespace?

Thanks

Michael

  • 5 months later...
  • Solution
Posted
18 minutes ago, WorkplaceConsultant said:

I need to upload a JSON file to my site and assign a custom link: /.well-known/did.json. If I understand correctly, that is not possible.

It is not possible.

Squarespace is a serverless platform, so this means you don't have access to a server and cannot place files in URL paths with prefixes like /.well-known/. On Squarespace, all files are store in /s/.

You'll need to host the file on a different web host or use an alternative method of achieving your goal.

Me: I'm Paul, a SQSP user for >18 yrs & Circle Leader since 2017. I value honesty, transparency, diversity and good design ♥.
Work: Founder of SF.DIGITAL. We provide high quality original extensions to supercharge your Squarespace website. 
Content: Views and opinions are my own. Links in my posts may refer to my own SF.DIGITAL products or may be affiliate links.
Forum advice is completely free. You can thank me by selecting a feedback emoji. Buying a coffee is generous but optional.

Posted
On 11/16/2022 at 6:43 PM, Michael_Thomson said:

Hey,

I'm looking to see if something is possible with SquareSpace before we agree to migrate over. 

We work with several partners who insist on doing validations with a file on the root domain rather than the preferred TXT record validation on DNS. For this we have to put a file in a folder at the root of the website in a folder called /.well-known. The file for example would be called test.devicemenagement and it would contain a text string for validation. 

This would then enable various partners to validate us on www.domain.com/.well-known/test.devicemanagemant

To further confuse this we need to add in a MIME type or contact to make sure the file extension of *.devicemanagement is downloaded as a JSON file.

Does anyone have any ideas of this is possible with Squarespace?

Thanks

Michael

I have the same question, have you  found a solution or work-around in the meantime?

  • 2 months later...
Posted

Hi all,

I'm trying to setup what Microsoft calls "Decentralized ID" in Entra (formerly Azure AD). As part of that I need to upload a json file to a specific URI in my site ((https://ariaconsulting.net/.well-known/did.json) and MS will then verify it. How can I accomplish this?

SQS support is utterly USELESS because I wasn't happy with their exceedingly limited template sites and had mine designed and built using the custom mode which they use as a shield to avoid supporting anything.

Thanks!

  • 1 year later...
Posted (edited)

To be fair, this is an odd requirement of Microsoft - by far the usual approach to domain verification is via DNS records, not files on the web server. Good news is you can actually do this (at least I could) - see below. No idea why Microsoft doesn't make this more clear on their App Registration page.

Solution:

For anyone else who was stuck on Azure App Registrations, trying to add a verified publisher domain in "Branding & Properties" using the "Update Domain" -> "Verify a new domain" button - there is actually another wasy to verify your domain - look for the link at the bottom of "Select a verified domain"

 

Screenshot2024-07-19at17_31_46.thumb.png.609229f41ee8e2695a730f73f5e9625b.png

 

This takes you to a list of your custom domains on Azure. Use "Add custom domain" to add a domain, and it will give you an option to add a TXT or MX record to verify the domain, instead of having to upload a special file to your web server (which you can't do with Squarespace). You can add a TXT or MX DNS record using Squarespace's domain settings.

Then, your verified domain is seletable as an option in "Branding & Properties"

 

Edited by jdallen
  • 4 weeks later...
Posted
On 4/22/2023 at 11:08 PM, paul2009 said:

It is not possible.

Squarespace is a serverless platform, so this means you don't have access to a server and cannot place files in URL paths with prefixes like /.well-known/. On Squarespace, all files are store in /s/.

You'll need to host the file on a different web host or use an alternative method of achieving your goal.

Hi Paul, I know your answer is marked as a solution, but is it possible that something has changed since then? 

Thank you 🙏

Posted
1 hour ago, NatalieSha said:

Hi Paul, I know your answer is marked as a solution, but is it possible that something has changed since then? 

Thank you 🙏

Can you try redirect method?

Assume your provider are expecting the same as the OP https://<domain>/.well-known/microsoft-identity-association.json

1. Upload the file to the site via Link manger

2. Find the file url at https://<domain>/s/microsoft-identity-association.json

3. Recommend: Trace the file to its source on Squarespace assets CDN, eg using wheregoes

image.thumb.png.7f489d11b9d695f52a9d64d05cae64f0.png

4. Now head to Settings > Developer Tools > URL Mappings

5. Add new line

5.1. If you do not trace to file source

/.well-known/microsoft-identity-association.json -> /s/microsoft-identity-association.json 301

5.2. If you do TRACE the file to its source, then use the static1.squarespace.com URL instead

/.well-known/microsoft-identity-association.json -> [static.squarespace.com...]microsoft-identity-association.json 301

It's a long shot since I did not know your provider, but the redirections works on some other cases, hope it can sastify your provider. So let us know if it works for your case 

 

Another alternative is use Cloudflare worker, which will require connecting Squarespace to Cloudflare as proxied mode (organge cloud). Then we can use Cloudflare worker to intercept request and serve the .well-known files properly

BeyondSpace - Squarespace Website Developer

🖼️ Lightbox Studio (Pinch/Zoom images, videos - PDFs Lightbox - ...) </>  🗓️ Delivery Date Picker (Date picker form field)
Gallery block 7.1 workaround </> 🤖 Ask me anything

  • 2 months later...
Posted
34 minutes ago, JakobL said:

This results in:

(ERROR_CODE_REDIRECT)

 (tested with https://developers.google.com/digital-asset-links/tools/generator)

 

For Apple it seems to work, tested with https://app-site-association.cdn-apple.com/a/v1/yourDomain.com

Yeah, it good to know, since google ads.txt works with redirect 

BeyondSpace - Squarespace Website Developer

🖼️ Lightbox Studio (Pinch/Zoom images, videos - PDFs Lightbox - ...) </>  🗓️ Delivery Date Picker (Date picker form field)
Gallery block 7.1 workaround </> 🤖 Ask me anything

Create an account or sign in to comment

You need to be a member in order to leave a comment

×
×
  • Create New...

Squarespace Webinars

Free online sessions where you’ll learn the basics and refine your Squarespace skills.

Hire a Designer

Stand out online with the help of an experienced designer or developer.