ttomcat-1778514358873.zip-extract/apache-tomcat-11.0.18-src/java/org/apache/tomcat/util/http/SameSiteCookies.java

Path
ttomcat-1778514358873.zip-extract/apache-tomcat-11.0.18-src/java/org/apache/tomcat/util/http/SameSiteCookies.java
Status
scanned
Type
file
Name
SameSiteCookies.java
Extension
.java
Programming language
Java
Mime type
text/plain
File type
ASCII text, with CRLF line terminators
Tag

      
    
Rootfs path

      
    
Size
2042 (2.0 KB)
MD5
57dff85d0513c05459430fbefc43d869
SHA1
5c435b1249069f4d825512510c10edfc8f28f708
SHA256
43432293f82bc628f9c68eb57a112e8e550ed049c198cbd0f2dec81afb24063e
SHA512

      
    
SHA1_git
23ec7f4468171506a2ed74da3efc15e0c63611a2
Is binary

      
    
Is text
True
Is archive

      
    
Is media

      
    
Is legal

      
    
Is manifest

      
    
Is readme

      
    
Is top level

      
    
Is key file

      
    
SameSiteCookies.java | 2.0 KB |

/* * Licensed to the Apache Software Foundation (ASF) under one or more * contributor license agreements. See the NOTICE file distributed with * this work for additional information regarding copyright ownership. * The ASF licenses this file to You under the Apache License, Version 2.0 * (the "License"); you may not use this file except in compliance with * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ package org.apache.tomcat.util.http; import org.apache.tomcat.util.res.StringManager; public enum SameSiteCookies { /** * Don't set the SameSite cookie attribute. */ UNSET("Unset"), /** * Cookie is always sent in cross-site requests. */ NONE("None"), /** * Cookie is only sent on same-site requests and cross-site top level navigation GET requests */ LAX("Lax"), /** * Prevents the cookie from being sent by the browser in all cross-site requests */ STRICT("Strict"); private static final StringManager sm = StringManager.getManager(SameSiteCookies.class); private final String value; SameSiteCookies(String value) { this.value = value; } public String getValue() { return value; } public static SameSiteCookies fromString(String value) { for (SameSiteCookies sameSiteCookies : values()) { if (sameSiteCookies.getValue().equalsIgnoreCase(value)) { return sameSiteCookies; } } throw new IllegalStateException(sm.getString("cookies.invalidSameSiteCookies", value)); } }
Detected license expression
apache-2.0
Detected license expression (SPDX)
Apache-2.0
Percentage of license text
50.42
Copyrights

      
    
Holders

      
    
Authors

      
    
License detections License expression License expression SPDX
apache_2_0-4bde3f57-78aa-4201-96bf-531cba09e7de apache-2.0 Apache-2.0
URL Start line End line
http://www.apache.org/licenses/LICENSE-2.0 9 9