You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/getting-started/gs-faqs.md
+1-1Lines changed: 1 addition & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -213,7 +213,7 @@ If a user opts out through your website, you should follow your internal procedu
213
213
214
214
In general yes, the process of generating a raw UID2 from DII is the same, and results in the same value, no matter who sent the request. If two UID2 participants were to send the same email address to the [POST /identity/map](../endpoints/post-identity-map.md) endpoint at the same time, they would both get the same raw UID2 in response.
215
215
216
-
However, there is a variable factor, which is the <Linkhref="../ref-info/glossary-uid#gl-salt">salt</Link> value that's used in generating the raw UID2. The salt values are rotated roughly once per year (for details, see [How often should UID2s be refreshed for incremental updates?](#how-often-should-uid2s-be-refreshed-for-incremental-updates)). If the salt value changes between one request and another, those two requests result in two different raw UID2, even when the DII is the same.
216
+
However, there is a variable factor, which is the secret <Linkhref="../ref-info/glossary-uid#gl-salt">salt</Link> value that's used in generating the raw UID2. The salt values are rotated roughly once per year (for details, see [How often should UID2s be refreshed for incremental updates?](#how-often-should-uid2s-be-refreshed-for-incremental-updates)). If the salt value changes between one request and another, those two requests result in two different raw UID2, even when the DII is the same.
217
217
218
218
For more information, see [Monitor for Salt Bucket Rotations for Your Stored Raw UID2s](../guides/integration-advertiser-dataprovider-overview.md#5-monitor-for-salt-bucket-rotations-for-your-stored-raw-uid2s) in the *Advertiser/Data Provider Integration Guide*.
Copy file name to clipboardExpand all lines: docs/getting-started/gs-normalization-encoding.md
+2-2Lines changed: 2 additions & 2 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -61,7 +61,7 @@ An email hash is a Base64-encoded <Link href="../ref-info/glossary-uid#gl-sha-25
61
61
| :--- | :--- | :--- |
62
62
| Normalized email address |`[email protected]`| Normalization is always the first step. |
63
63
| SHA-256 hash of normalized email address |`b4c9a289323b21a01c3e940f150eb9b8c542587f1abfd8f0e1cc1ffc5e475514`| This 64-character string is a hex-encoded representation of the 32-byte SHA-256. |
64
-
| Hex to Base64 SHA-256 encoding of normalized email address|`tMmiiTI7IaAcPpQPFQ65uMVCWH8av9jw4cwf/F5HVRQ=`| This 44-character string is a Base64-encoded representation of the 32-byte SHA-256.<br/>WARNING: The SHA-256 hash string in the example above is a hex-encoded representation of the hash value. You must Base64-encode the raw bytes of the hash or use a Base64 encoder that takes a hex-encoded value as input.<br/>Use this encoding for `email_hash` values sent in the request body. |
64
+
| Hex to Base64 encoding of SHA-256 hash|`tMmiiTI7IaAcPpQPFQ65uMVCWH8av9jw4cwf/F5HVRQ=`| This 44-character string is a Base64-encoded representation of the 32-byte SHA-256.<br/>WARNING: The SHA-256 hash string in the example above is a hex-encoded representation of the hash value. You must Base64-encode the raw bytes of the hash or use a Base64 encoder that takes a hex-encoded value as input.<br/>Use this encoding for `email_hash` values sent in the request body. |
65
65
66
66
:::important
67
67
When applying Base64 encoding, be sure to Base64-encode the raw bytes of the hash or use a Base64 encoder that takes a hex-encoded value as input.
@@ -100,7 +100,7 @@ The following table shows an example of a simple input phone number, and the res
100
100
| :--- | :--- | :--- |
101
101
| Normalized phone number |`+12345678901`| Normalization is always the first step. |
102
102
| SHA-256 hash of normalized phone number |`10e6f0b47054a83359477dcb35231db6de5c69fb1816e1a6b98e192de9e5b9ee`|This 64-character string is a hex-encoded representation of the 32-byte SHA-256. |
103
-
| Hex to Base64 SHA-256 encoding of normalized and hashed phone number|`EObwtHBUqDNZR33LNSMdtt5cafsYFuGmuY4ZLenlue4=`| This 44-character string is a Base64-encoded representation of the 32-byte SHA-256.<br/>NOTE: The SHA-256 hash is a hexadecimal value. You must use a Base64 encoder that takes a hex value as input. Use this encoding for `phone_hash` values sent in the request body. |
103
+
| Hex to Base64 encoding of SHA-256 hash|`EObwtHBUqDNZR33LNSMdtt5cafsYFuGmuY4ZLenlue4=`| This 44-character string is a Base64-encoded representation of the 32-byte SHA-256.<br/>NOTE: The SHA-256 hash is a hexadecimal value. You must use a Base64 encoder that takes a hex value as input. Use this encoding for `phone_hash` values sent in the request body. |
104
104
105
105
:::warning
106
106
When applying Base64 encoding, be sure to use a function that takes a hex value as input. If you use a function that takes text as input, the result is a longer string which is invalid for the purposes of UID2.
<dd>The UID2 Core Service is a centralized service that manages access to <ahref="#gl-salt">salts</a>, encryption keys, and other relevant data in the UID2 ecosystem.</dd>
207
+
<dd>The UID2 Core Service is a centralized service that manages access to secret <ahref="#gl-salt">salts</a>, encryption keys, and other relevant data in the UID2 ecosystem.</dd>
208
208
<dd>For an overview of all the UID2 services, see <ahref="../intro#components">Components</a>.</dd>
209
209
210
210
</dl>
@@ -339,7 +339,7 @@ import Link from '@docusaurus/Link';
<dd>An Operator is an organization or entity that runs the UID2 <ahref="#gl-operator-service">Operator Service</a>. The UID2 Operator is the API server in the UID2 ecosystem.</dd>
342
-
<dd>Operators perform multiple functions, such as receiving <ahref="#gl-encryption-key">encryption keys</a> and <ahref="#gl-salt">salts</a> from the UID2 Core Service, salting and hashing personal data (<Linkhref="#gl-dii">DII</Link>) to return raw UID2s, and encrypting raw UID2s to generate UID2 tokens.</dd>
342
+
<dd>Operators perform multiple functions, such as receiving <ahref="#gl-encryption-key">encryption keys</a> and secret <ahref="#gl-salt">salts</a> from the UID2 Core Service, salting and hashing personal data (<Linkhref="#gl-dii">DII</Link>) to return raw UID2s, and encrypting raw UID2s to generate UID2 tokens.</dd>
343
343
<dd>A participant can also choose to become a <ahref="#gl-private-operator">Private Operator</a> to access UID2 APIs and to generate raw UID2s and UID2 tokens from within a private infrastructure.</dd>
344
344
<dd>For details, see <ahref="../intro#participants">participants</a> and <ahref="../ref-info/ref-operators-public-private">The UID2 Operator</a>.</dd>
345
345
@@ -406,15 +406,15 @@ import Link from '@docusaurus/Link';
<dd>A string of characters that is used in the process of transforming an email address or phone number into a secure, opaque value that cannot by itself be traced back to the original value (raw UID2 or UID2 token).</dd>
409
+
<dd>A string of characters that is used in the process of transforming an email address or phone number into a secure, opaque value that cannot by itself be traced back to the original value (raw UID2 or UID2 token). Salt values are kept secret.</dd>
410
410
<dd>The UID2 service uses salt as part of the process, along with hashing and encryption, to secure the original value. Salt is added to the input value before hashing.</dd>
<dd>A salt bucket is used to manage secret <ahref="#gl-salt">salt</a> values, used to generate raw UID2s or UID2 tokens, over time. Each bucket contains a single current salt value, which remains active for approximately one year before being rotated to a new value. Buckets can be updated independently of one another.</dd>
414
414
<dd>There are just over one million salt buckets, and each email address or phone number is assigned to a specific bucket in a deterministic manner. However, this assignment is not permanent; it might change when the bucket's current secret salt is rotated to a new value.</dd>
<dd>A salt bucket ID is a unique string of characters that identifies a specific <ahref="#gl-salt-bucket">salt bucket</a>. The salt bucket ID can be used to check which salt buckets have recently had their salt values updated, indicating which emails or phone numbers need their raw UID2 values regenerated.</dd>
417
+
<dd>A salt bucket ID is a unique string of characters that identifies a specific <ahref="#gl-salt-bucket">salt bucket</a>. The salt bucket ID can be used to check which salt buckets have recently had their secret salt values updated, indicating which emails or phone numbers need their raw UID2 values regenerated.</dd>
418
418
<dd>For an example of a salt bucket ID, see the response to the `POST /identity/buckets` endpoint: <ahref="../endpoints/post-identity-buckets#decrypted-json-response-format">Decrypted JSON Response Format</a>.</dd>
@@ -510,7 +510,7 @@ import Link from '@docusaurus/Link';
510
510
<dd>The token value is opaque: No assumptions should be made about the format or about the length of the string.</dd>
511
511
<dd>The token has a limited life, but can be refreshed in the background using the <ahref="#gl-refresh-token">refresh token</a>.</dd>
512
512
<dd>Publishers send UID2 tokens in the bidstream.</dd>
513
-
<dd>For details, see <ahref="../intro#uid2-identifier-types">UID2 Identifier Types</a> and <ahref="ref-tokens#uid2-tokens-key-information">UID2 Tokens: Key Information</a>.</dd>
513
+
<dd>For details, see <ahref="../intro#uid2-identifier-types">UID2 Identifier Types</a>, <ahref="ref-tokens#uid2-tokens-key-information">UID2 Tokens: Key Information</a>, and <ahref="ref-how-uid-is-created">How the UID2 Token Is Created</a>.</dd>
514
514
515
515
<dt><MdxJumpAnchorid="gl-unified-id-20"><ahref="#gl-unified-id-20">Unified ID 2.0</a></MdxJumpAnchor></dt>
516
516
<dd>The term UID2 can be used to mean the <ahref="#gl-uid2-framework">UID2 framework</a>, the <ahref="#gl-uid2-service">UID2 service</a>, a <ahref="#gl-raw-uid2">raw UID2</a>, or a <ahref="#gl-uid2-token">UID2 token</a> (advertising token).</dd>
description: Reference information about the process for generating a UID2 token.
4
+
hide_table_of_contents: false
5
+
sidebar_position: 06
6
+
---
7
+
8
+
import Link from '@docusaurus/Link';
9
+
10
+
# How the UID2 Token Is Created
11
+
12
+
:::note
13
+
This article describes how the UID2 token that the publisher sends in the bidstream is created. The process is the same for advertisers creating UID2 tokens for conversion pixels. It does not apply to <Linkhref="../ref-info/glossary-uid#gl-tokenized-sharing">tokenized sharing</Link>, where raw UID2s are encrypted into UID2 tokens before sending to another sharing participant.
14
+
:::
15
+
16
+
When a publisher sends a user's <Linkhref="../ref-info/glossary-uid#gl-dii">DII</Link>—<Linkhref="../ref-info/glossary-uid#gl-hash">hashed</Link> or unhashed email addresses or phone numbers—to the UID2 <Linkhref="../ref-info/glossary-uid#gl-operator">Operator</Link>, and in return receives a <Linkhref="../ref-info/glossary-uid#gl-uid2-token">UID2 token</Link> to use for targeted advertising, there is a very specific sequence of processing steps that occurs along the way.
17
+
18
+
Some preliminary steps are taken by the publisher, but most of the processing steps are done by the UID2 Operator.
19
+
20
+
It's very important that the publisher steps are performed in the correct sequence:
21
+
- When steps are performed in sequence, the resulting value can be recognized as related to other [UID2 identifiers](../intro.md#uid2-identifier-types) generated from online activity by the same individual: the underlying [raw UID2](../ref-info/glossary-uid.md#gl-raw-uid2) matches the raw UID2s generated by other UID2 participants from the same DII, and therefore the token is suitable for targeted advertising.
22
+
- If steps are taken out of sequence, the resulting value cannot be related to other UID2 identifiers generated from online activity by the same individual, and therefore the token is not suitable for targeted advertising.
23
+
24
+
For a summary, see [Steps to Create a UID2 Token](#steps-to-create-a-uid2-token). For an example in diagram form, see [Creating a UID2 Token—Example](#creating-a-uid2-tokenexample).
25
+
26
+
## Steps to Create a UID2 Token
27
+
28
+
The following table shows the steps for creating a UID2 token from DII, the sequence, and who performs each step.
29
+
30
+
For an example with sample values, see [Creating a UID2 Token—Example](#creating-a-uid2-tokenexample).
<td>**Email**: Publisher or UID2 Operator<br/>**Phone number**: Publisher must normalize</td>
46
+
<td>[Email Address Normalization](../getting-started/gs-normalization-encoding.md#email-address-normalization)<br/>[Phone Number Normalization](../getting-started/gs-normalization-encoding.md#phone-number-normalization)</td>
47
+
</tr>
48
+
<tr>
49
+
<td>2</td>
50
+
<td>Apply <Link href="../ref-info/glossary-uid#gl-sha-256">SHA-256</Link> hashing to the normalized email address.</td>
51
+
<td>Publisher or UID2 Operator</td>
52
+
<td>[Email Address Hash Encoding](../getting-started/gs-normalization-encoding.md#email-address-hash-encoding)<br/>[Phone Number Hash Encoding](../getting-started/gs-normalization-encoding.md#phone-number-hash-encoding)</td>
53
+
</tr>
54
+
<tr>
55
+
<td>3</td>
56
+
<td>Apply Base64 encoding to the SHA-256 hash.</td>
57
+
<td>Publisher or UID2 Operator</td>
58
+
<td>[Email Address Hash Encoding](../getting-started/gs-normalization-encoding.md#email-address-hash-encoding)<br/>[Phone Number Hash Encoding](../getting-started/gs-normalization-encoding.md#phone-number-hash-encoding)</td>
59
+
</tr>
60
+
<tr>
61
+
<td>4</td>
62
+
<td>Send value to UID2 Operator via the [POST /token/generate](../endpoints/post-token-generate.md) endpoint, an SDK, Prebid.js, or another supported integration.</td>
63
+
<td>Publisher</td>
64
+
<td>Various: for a summary, see [Implementation Resources](../overviews/overview-publishers.md#implementation-resources)</td>
65
+
</tr>
66
+
<tr>
67
+
<td>5</td>
68
+
<td>Perform multiple steps including hashing and adding the secret <Link href="../ref-info/glossary-uid#gl-salt">salt</Link> value to create a raw UID2.</td>
69
+
<td>UID2 Operator</td>
70
+
<td>Not applicable: these steps are all performed by the UID2 Operator.</td>
71
+
</tr>
72
+
<tr>
73
+
<td>6</td>
74
+
<td>Encrypt the raw UID2 to create a UID2 token.</td>
75
+
<td>UID2 Operator</td>
76
+
<td>Not applicable: performed by the UID2 Operator.</td>
77
+
</tr>
78
+
</tbody>
79
+
</table>
80
+
81
+
## Creating a UID2 Token—Example
82
+
83
+
The following diagram shows the high-level steps for creating a [raw UID2](../ref-info/glossary-uid.md#gl-raw-uid2) (first column, second column) and then a [UID2 token](../ref-info/glossary-uid.md#gl-uid2-token) (third column).
84
+
85
+
The publisher can send a request to the [POST /token/generate](../endpoints/post-token-generate.md) endpoint or use one of the other integration options, such as an SDK or Prebid. Whatever the integration option, the result is a UID2 token—an encrypted value that the publisher can send in the bidstream for targeted advertising.
86
+
87
+

0 commit comments