Skip to content

Commit

Permalink
Add "Sec-GPC" header.
Browse files Browse the repository at this point in the history
  • Loading branch information
java-team-github-bot authored and Google Java Core Libraries committed Apr 22, 2024
1 parent d092aed commit 38c8017
Show file tree
Hide file tree
Showing 4 changed files with 22 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -51,8 +51,8 @@ public void testConstantNameMatchesString() throws Exception {
.buildOrThrow();
ImmutableSet<String> uppercaseAcronyms =
ImmutableSet.of(
"CH", "ID", "DNT", "DNS", "DPR", "ECT", "HTTP2", "IP", "MD5", "P3P", "RTT", "TE", "UA",
"UID", "URL", "WWW", "XSS");
"CH", "ID", "DNT", "DNS", "DPR", "ECT", "GPC", "HTTP2", "IP", "MD5", "P3P", "RTT", "TE",
"UA", "UID", "URL", "WWW", "XSS");
assertConstantNameMatchesString(HttpHeaders.class, specialCases, uppercaseAcronyms);
}

Expand Down
9 changes: 9 additions & 0 deletions android/guava/src/com/google/common/net/HttpHeaders.java
Original file line number Diff line number Diff line change
Expand Up @@ -874,6 +874,15 @@ private ReferrerPolicyValues() {}
*/
public static final String SEC_AD_AUCTION_FETCH = "Sec-Ad-Auction-Fetch";

/**
* The HTTP <a
* href="https://privacycg.github.io/gpc-spec/#the-sec-gpc-header-field-for-http-requests">{@code
* Sec-GPC}</a> header field name.
*
* @since NEXT
*/
public static final String SEC_GPC = "Sec-GPC";

/**
* The HTTP <a
* href="https://wicg.github.io/turtledove/#handling-direct-from-seller-signals">{@code
Expand Down
4 changes: 2 additions & 2 deletions guava-tests/test/com/google/common/net/HttpHeadersTest.java
Original file line number Diff line number Diff line change
Expand Up @@ -51,8 +51,8 @@ public void testConstantNameMatchesString() throws Exception {
.buildOrThrow();
ImmutableSet<String> uppercaseAcronyms =
ImmutableSet.of(
"CH", "ID", "DNT", "DNS", "DPR", "ECT", "HTTP2", "IP", "MD5", "P3P", "RTT", "TE", "UA",
"UID", "URL", "WWW", "XSS");
"CH", "ID", "DNT", "DNS", "DPR", "ECT", "GPC", "HTTP2", "IP", "MD5", "P3P", "RTT", "TE",
"UA", "UID", "URL", "WWW", "XSS");
assertConstantNameMatchesString(HttpHeaders.class, specialCases, uppercaseAcronyms);
}

Expand Down
9 changes: 9 additions & 0 deletions guava/src/com/google/common/net/HttpHeaders.java
Original file line number Diff line number Diff line change
Expand Up @@ -874,6 +874,15 @@ private ReferrerPolicyValues() {}
*/
public static final String SEC_AD_AUCTION_FETCH = "Sec-Ad-Auction-Fetch";

/**
* The HTTP <a
* href="https://privacycg.github.io/gpc-spec/#the-sec-gpc-header-field-for-http-requests">{@code
* Sec-GPC}</a> header field name.
*
* @since NEXT
*/
public static final String SEC_GPC = "Sec-GPC";

/**
* The HTTP <a
* href="https://wicg.github.io/turtledove/#handling-direct-from-seller-signals">{@code
Expand Down

0 comments on commit 38c8017

Please sign in to comment.