ttomcat-1778514358873.zip-extract/apache-tomcat-11.0.18-src/java/jakarta/security/auth/message/callback/PasswordValidationCallback.java

Path
ttomcat-1778514358873.zip-extract/apache-tomcat-11.0.18-src/java/jakarta/security/auth/message/callback/PasswordValidationCallback.java
Status
scanned
Type
file
Name
PasswordValidationCallback.java
Extension
.java
Programming language
Java
Mime type
text/plain
File type
ASCII text, with CRLF line terminators
Tag

      
    
Rootfs path

      
    
Size
2035 (2.0 KB)
MD5
36c16ccd953a32cb03b01d381204ea92
SHA1
0b19ad788571fc50645fddfbfda507b5ee8f245a
SHA256
33883a7667f7de00d9204d83b848e78623e6da50501c50e2737ac4db6f1498c6
SHA512

      
    
SHA1_git
4cb77a67f0faa2ed60beae05d7344efb9a186595
Is binary

      
    
Is text
True
Is archive

      
    
Is media

      
    
Is legal

      
    
Is manifest

      
    
Is readme

      
    
Is top level

      
    
Is key file

      
    
PasswordValidationCallback.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 jakarta.security.auth.message.callback; import java.util.Arrays; import javax.security.auth.Subject; import javax.security.auth.callback.Callback; /** * Callback that enables an authentication module to supply a username and password (to a runtime?) and determine if the * result of validation. */ public class PasswordValidationCallback implements Callback { private final Subject subject; private final String username; private char[] password; private boolean result; public PasswordValidationCallback(Subject subject, String username, char[] password) { this.subject = subject; this.username = username; this.password = password; } public Subject getSubject() { return subject; } public String getUsername() { return username; } public char[] getPassword() { return password; } public void clearPassword() { Arrays.fill(password, (char) 0); password = new char[0]; } public void setResult(boolean result) { this.result = result; } public boolean getResult() { return result; } }
Detected license expression
apache-2.0
Detected license expression (SPDX)
Apache-2.0
Percentage of license text
50.64
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