승인되지 않은 사용자가 내 API 키를 사용하여 내 도메인에서 내가 소유하지 않은 사이트로 리디렉션되는 Dynamic Links를 만들지 못하도록 하려면 Dynamic Links가 리디렉션할 수 있는 URL을 지정해야 합니다.
허용된 URL을 지정하려면 Firebase 콘솔의 Dynamic Links 페이지에서 more_vert> 허용 목록 URL 패턴을 클릭한 다음 RE2 문법을 사용하여 최대 10개의 정규 표현식을 지정합니다. 이러한 정규 표현식 중 하나와 일치하는 URL만 Dynamic Links의 딥 링크(link) 또는 대체 링크(afl, ifl, ipfl, ofl)로 사용할 수 있습니다. URL 패턴을 지정하면 패턴 중 하나와 일치하지 않는 URL은 Dynamic Links에서 HTTP 오류 400을 반환합니다.
URL 패턴은 최대한 제한적으로 만들어야 합니다. 예를 들면 다음과 같습니다.
너무 관대함
더 좋음
^https://.*.com/.*$
.com으로 끝나는 사이트의 모든 페이지로 리디렉션할 수 있습니다.
^https://mybrand\.com/.*$
mybrand.com의 페이지로만 리디렉션할 수 있습니다.
^https://play.google.com/.*$
앱의 Google Play Store 페이지로 리디렉션할 수 있습니다.
^https://play\.google\.com/.*id=myapp\.com$
패키지 이름이 myapp.com인 앱의 Google Play Store 페이지로만 리디렉션할 수 있습니다.
^https://itunes.apple.com/.*$
itunes.apple.com의 모든 페이지로 리디렉션할 수 있습니다.
^https://itunes\.apple\.com/.*id123$
ID가 id123인 앱의 App Store 페이지로만 리디렉션할 수 있습니다.
Dynamic Links의 디버그 페이지를 보고 경고가 없는지 확인하여 Dynamic Links의 딥 링크와 대체 링크가 URL 패턴 중 하나와 일치하는지 확인할 수 있습니다.
[[["이해하기 쉬움","easyToUnderstand","thumb-up"],["문제가 해결됨","solvedMyProblem","thumb-up"],["기타","otherUp","thumb-up"]],[["필요한 정보가 없음","missingTheInformationINeed","thumb-down"],["너무 복잡함/단계 수가 너무 많음","tooComplicatedTooManySteps","thumb-down"],["오래됨","outOfDate","thumb-down"],["번역 문제","translationIssue","thumb-down"],["샘플/코드 문제","samplesCodeIssue","thumb-down"],["기타","otherDown","thumb-down"]],["최종 업데이트: 2025-08-18(UTC)"],[],[],null,["\u003cbr /\u003e\n\n| **Deprecated:** Firebase Dynamic Links is *deprecated* and should not be adopted in projects that don't already use it. The service will shut down on August 25, 2025. See the [Dynamic Links Deprecation FAQ](/support/dynamic-links-faq) for more information.\n\nTo prevent unauthorized parties from using your API key to create Dynamic Links that\nredirect from your domain to sites you don't own, you should specify the URLs\nyour Dynamic Links can redirect to.\n\nTo specify the allowed URLs, click\nmore_vert **\\\u003e Allowlist URL pattern**\nfrom the Dynamic Links page of the Firebase console, and then specify up to\n10 regular expressions using\n[RE2 syntax](https://github.com/google/re2/wiki/Syntax). Only URLs\nthat match one of these regular expressions can be successfully used as a deep\nlink (`link`) or fallback link (`afl`, `ifl`, `ipfl`, `ofl`) for a Dynamic Links. If\nyou specify URL patterns, any URL that doesn't match one of the patterns will\ncause your Dynamic Links to return HTTP error 400.\n\nYou should make your URL patterns as restrictive as possible. For example:\n\n| Too permissive | Better |\n|----------------------------------------------------------------------------------|-------------------------------------------------------------------------------------------------------------------------------------------|\n| `^https://.*.com/.*$` Can redirect to any page on any site ending with `.com`. | `^https://mybrand\\.com/.*$` Can redirect only to pages at `mybrand.com`. |\n| `^https://play.google.com/.*$` Can redirect to any app's Google Play Store page. | `^https://play\\.google\\.com/.*id=myapp\\.com$` Can redirect only to Google Play Store pages for the app with the package name `myapp.com`. |\n| `^https://itunes.apple.com/.*$` Can redirect to any page on `itunes.apple.com`. | `^https://itunes\\.apple\\.com/.*id123$` Can redirect only to the App Store page for the app with the ID `id123`. |\n\nYou can make sure a deep link and fallback links for a Dynamic Links match one of\nyour URL patterns by viewing the debug page for Dynamic Links and verifying there are\nno warnings: \n\n```\nhttps://example.page.link/WXYZ?d=1\n```"]]