001 /* 002 * Licensed to the Apache Software Foundation (ASF) under one 003 * or more contributor license agreements. See the NOTICE file 004 * distributed with this work for additional information 005 * regarding copyright ownership. The ASF licenses this file 006 * to you under the Apache License, Version 2.0 (the 007 * "License"); you may not use this file except in compliance 008 * with the License. You may obtain a copy of the License at 009 * 010 * http://www.apache.org/licenses/LICENSE-2.0 011 * 012 * Unless required by applicable law or agreed to in writing, 013 * software distributed under the License is distributed on an 014 * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 015 * KIND, either express or implied. See the License for the 016 * specific language governing permissions and limitations 017 * under the License. 018 * 019 */ 020 package org.apache.directory.server.changepw.service; 021 022 023 import java.net.InetAddress; 024 025 import org.apache.directory.server.changepw.ChangePasswordServer; 026 import org.apache.directory.server.changepw.messages.AbstractPasswordMessage; 027 import org.apache.directory.server.kerberos.shared.crypto.encryption.CipherTextHandler; 028 import org.apache.directory.server.kerberos.shared.messages.ApplicationRequest; 029 import org.apache.directory.server.kerberos.shared.messages.components.Authenticator; 030 import org.apache.directory.server.kerberos.shared.messages.components.Ticket; 031 import org.apache.directory.server.kerberos.shared.replay.ReplayCache; 032 import org.apache.directory.server.kerberos.shared.store.PrincipalStore; 033 import org.apache.directory.server.kerberos.shared.store.PrincipalStoreEntry; 034 035 036 /** 037 * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a> 038 * @version $Rev: 583938 $, $Date: 2007-10-11 21:57:20 +0200 (Thu, 11 Oct 2007) $ 039 */ 040 public class ChangePasswordContext 041 { 042 private static final long serialVersionUID = -5124209294966799740L; 043 044 private ChangePasswordServer config; 045 private PrincipalStore store; 046 private AbstractPasswordMessage request; 047 private AbstractPasswordMessage reply; 048 private InetAddress clientAddress; 049 050 private ApplicationRequest authHeader; 051 private Ticket ticket; 052 private Authenticator authenticator; 053 private PrincipalStoreEntry serverEntry; 054 private ReplayCache replayCache; 055 private CipherTextHandler cipherTextHandler; 056 private String password; 057 058 059 /** 060 * @return Returns the replayCache. 061 */ 062 public ReplayCache getReplayCache() 063 { 064 return replayCache; 065 } 066 067 068 /** 069 * @param replayCache The replayCache to set. 070 */ 071 public void setReplayCache( ReplayCache replayCache ) 072 { 073 this.replayCache = replayCache; 074 } 075 076 077 /** 078 * @return Returns the serverEntry. 079 */ 080 public PrincipalStoreEntry getServerEntry() 081 { 082 return serverEntry; 083 } 084 085 086 /** 087 * @param serverEntry The serverEntry to set. 088 */ 089 public void setServerEntry( PrincipalStoreEntry serverEntry ) 090 { 091 this.serverEntry = serverEntry; 092 } 093 094 095 /** 096 * @return Returns the config. 097 */ 098 public ChangePasswordServer getConfig() 099 { 100 return config; 101 } 102 103 104 /** 105 * @param config The config to set. 106 */ 107 public void setConfig( ChangePasswordServer config ) 108 { 109 this.config = config; 110 } 111 112 113 /** 114 * @return Returns the reply. 115 */ 116 public AbstractPasswordMessage getReply() 117 { 118 return reply; 119 } 120 121 122 /** 123 * @param reply The reply to set. 124 */ 125 public void setReply( AbstractPasswordMessage reply ) 126 { 127 this.reply = reply; 128 } 129 130 131 /** 132 * @return Returns the request. 133 */ 134 public AbstractPasswordMessage getRequest() 135 { 136 return request; 137 } 138 139 140 /** 141 * @param request The request to set. 142 */ 143 public void setRequest( AbstractPasswordMessage request ) 144 { 145 this.request = request; 146 } 147 148 149 /** 150 * @return Returns the store. 151 */ 152 public PrincipalStore getStore() 153 { 154 return store; 155 } 156 157 158 /** 159 * @param store The store to set. 160 */ 161 public void setStore( PrincipalStore store ) 162 { 163 this.store = store; 164 } 165 166 167 /** 168 * @return Returns the {@link CipherTextHandler}. 169 */ 170 public CipherTextHandler getCipherTextHandler() 171 { 172 return cipherTextHandler; 173 } 174 175 176 /** 177 * @param cipherTextHandler The {@link CipherTextHandler} to set. 178 */ 179 public void setCipherTextHandler( CipherTextHandler cipherTextHandler ) 180 { 181 this.cipherTextHandler = cipherTextHandler; 182 } 183 184 185 /** 186 * @return Returns the authenticator. 187 */ 188 public Authenticator getAuthenticator() 189 { 190 return authenticator; 191 } 192 193 194 /** 195 * @param authenticator The authenticator to set. 196 */ 197 public void setAuthenticator( Authenticator authenticator ) 198 { 199 this.authenticator = authenticator; 200 } 201 202 203 /** 204 * @return Returns the authHeader. 205 */ 206 public ApplicationRequest getAuthHeader() 207 { 208 return authHeader; 209 } 210 211 212 /** 213 * @param authHeader The authHeader to set. 214 */ 215 public void setAuthHeader( ApplicationRequest authHeader ) 216 { 217 this.authHeader = authHeader; 218 } 219 220 221 /** 222 * @return Returns the ticket. 223 */ 224 public Ticket getTicket() 225 { 226 return ticket; 227 } 228 229 230 /** 231 * @param ticket The ticket to set. 232 */ 233 public void setTicket( Ticket ticket ) 234 { 235 this.ticket = ticket; 236 } 237 238 239 /** 240 * @return Returns the clientAddress. 241 */ 242 public InetAddress getClientAddress() 243 { 244 return clientAddress; 245 } 246 247 248 /** 249 * @param clientAddress The clientAddress to set. 250 */ 251 public void setClientAddress( InetAddress clientAddress ) 252 { 253 this.clientAddress = clientAddress; 254 } 255 256 257 /** 258 * @return Returns the password. 259 */ 260 public String getPassword() 261 { 262 return password; 263 } 264 265 266 /** 267 * @param password The password to set. 268 */ 269 public void setPassword( String password ) 270 { 271 this.password = password; 272 } 273 }