1 16 17 package org.apache.coyote.tomcat4; 18 19 import java.io.File ; 20 import java.net.InetAddress ; 21 import java.net.ServerSocket ; 22 23 24 53 54 public class CoyoteServerSocketFactory 55 implements org.apache.catalina.net.ServerSocketFactory { 56 57 58 60 61 64 private String algorithm = null; 65 66 public String getAlgorithm() { 67 return (this.algorithm); 68 } 69 70 public void setAlgorithm(String algorithm) { 71 this.algorithm = algorithm; 72 } 73 74 75 78 private String clientAuth = "false"; 79 80 public String getClientAuth() { 81 return (this.clientAuth); 82 } 83 84 public void setClientAuth(String clientAuth) { 85 this.clientAuth = clientAuth; 86 } 87 88 89 92 private String keystoreFile = 93 System.getProperty("user.home") + File.separator + ".keystore"; 94 95 public String getKeystoreFile() { 96 return (this.keystoreFile); 97 } 98 99 public void setKeystoreFile(String keystoreFile) { 100 101 File file = new File (keystoreFile); 102 if (!file.isAbsolute()) 103 file = new File (System.getProperty("catalina.base"), 104 keystoreFile); 105 this.keystoreFile = file.getAbsolutePath(); 106 } 107 108 111 private String randomFile = 112 System.getProperty("user.home") + File.separator + "random.pem"; 113 114 public String getRandomFile() { 115 return (this.randomFile); 116 } 117 118 public void setRandomFile(String randomFile) { 119 120 File file = new File (randomFile); 121 if (!file.isAbsolute()) 122 file = new File (System.getProperty("catalina.base"), 123 randomFile); 124 this.randomFile = file.getAbsolutePath(); 125 } 126 127 130 private String rootFile = 131 System.getProperty("user.home") + File.separator + "root.pem"; 132 133 public String getRootFile() { 134 return (this.rootFile); 135 } 136 137 public void setRootFile(String rootFile) { 138 139 File file = new File (rootFile); 140 if (!file.isAbsolute()) 141 file = new File (System.getProperty("catalina.base"), 142 rootFile); 143 this.rootFile = file.getAbsolutePath(); 144 } 145 146 149 private String keystorePass = "changeit"; 150 151 public String getKeystorePass() { 152 return (this.keystorePass); 153 } 154 155 public void setKeystorePass(String keystorePass) { 156 this.keystorePass = keystorePass; 157 } 158 159 160 163 private String keystoreType = "JKS"; 164 165 public String getKeystoreType() { 166 return (this.keystoreType); 167 } 168 169 public void setKeystoreType(String keystoreType) { 170 this.keystoreType = keystoreType; 171 } 172 173 174 177 private String protocol = "TLS"; 178 179 public String getProtocol() { 180 return (this.protocol); 181 } 182 183 public void setProtocol(String protocol) { 184 this.protocol = protocol; 185 } 186 187 188 191 private String sslImplementation = null; 192 193 public String getSSLImplementation() { 194 return (this.sslImplementation); 195 } 196 197 public void setSSLImplementation(String sslImplementation) { 198 this.sslImplementation = sslImplementation; 199 } 200 201 202 203 205 206 public ServerSocket createSocket(int port) { 207 return (null); 208 } 209 210 211 public ServerSocket createSocket(int port, int backlog) { 212 return (null); 213 } 214 215 216 public ServerSocket createSocket(int port, int backlog, 217 InetAddress ifAddress) { 218 return (null); 219 } 220 221 222 } 223 | Popular Tags |