Guide to create a whitelist pattern for Dynamic Links

5,201 views
Skip to first unread message

Naren Keshav

unread,
Feb 23, 2020, 10:49:40 PM2/23/20
to Firebase Google Group

Target Platform : iOS & Android

Dev Platform : Unity3D

 

Base URL Prefix is : https://mani.games/view/

 

My intention is to create a Dynamic Link with path length Unguessable.

[https://firebase.google.com/docs/reference/unity/namespace/firebase/dynamic-links#namespace_firebase_1_1_dynamic_links_1afe4f24b8500b4f05ca178978b793b374]

 

Every time I create, I get a warning

 

There is no configuration to prevent phishing on this domain https://mani.games/view. Setup URL patterns to whitelist in the Firebase Dynamic Links console. [https://support.google.com/firebase/answer/9021429]

 

When I create, I get a dynamic link like https://mani.games/view/kHKjJgduPdgViW9G9

 

My fallback URL will be added when the app is published.

 

What should the regex be? My experience with regex & whitelisting is quite minimal.

Could someone guide/help me?


Thank you.

Patrick Martin

unread,
Feb 26, 2020, 12:50:14 PM2/26/20
to Firebase Google Group
I think that you should be able to enter:
^https://mani\.games/view/.*$
And have a good pattern. A quick breakdown:
`^` means "the start of the line"
`.` actually means match any character. So you have to type `\.` to say "match a period"
`*` means "match the previous item 0 to many times."
`$` means "this is the end of the line"

So the full interpretation is "match the beginning of the line then 'https://mani', match an actual '.', 'games/view/', match any number of extra elements (such as the string of numbers and letters for the dynamic link), and finally find the end of the line".

Let me know if that helps,
--Patrick

Naren Keshav

unread,
Feb 27, 2020, 10:06:10 AM2/27/20
to Firebase Google Group
Thank you for your reply Patrick. That was awesome.
From this reference
They also mentioned URL the respective stores (iOS & Android).
  1. Do I have to mention such a regex pattern?
  2. Is it mandatory?

Thank you
Reply all
Reply to author
Forward
0 new messages