src/java.base/share/classes/sun/net/www/http/HttpCapture.java
author dfuchs
Fri, 30 Aug 2019 15:42:27 +0100
branchJDK-8229867-branch
changeset 57968 8595871a5446
parent 47216 71c04702a3d5
permissions -rw-r--r--
JDK-8229867: first prototype
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
3059
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
     1
/*
5506
202f599c92aa 6943119: Rebrand source copyright notices
ohair
parents: 3866
diff changeset
     2
 * Copyright (c) 2009, Oracle and/or its affiliates. All rights reserved.
3059
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
     3
 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
     4
 *
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
     5
 * This code is free software; you can redistribute it and/or modify it
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
     6
 * under the terms of the GNU General Public License version 2 only, as
5506
202f599c92aa 6943119: Rebrand source copyright notices
ohair
parents: 3866
diff changeset
     7
 * published by the Free Software Foundation.  Oracle designates this
3059
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
     8
 * particular file as subject to the "Classpath" exception as provided
5506
202f599c92aa 6943119: Rebrand source copyright notices
ohair
parents: 3866
diff changeset
     9
 * by Oracle in the LICENSE file that accompanied this code.
3059
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
    10
 *
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
    11
 * This code is distributed in the hope that it will be useful, but WITHOUT
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
    12
 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
    13
 * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
    14
 * version 2 for more details (a copy is included in the LICENSE file that
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
    15
 * accompanied this code).
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
    16
 *
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
    17
 * You should have received a copy of the GNU General Public License version
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
    18
 * 2 along with this work; if not, write to the Free Software Foundation,
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
    19
 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
    20
 *
5506
202f599c92aa 6943119: Rebrand source copyright notices
ohair
parents: 3866
diff changeset
    21
 * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
202f599c92aa 6943119: Rebrand source copyright notices
ohair
parents: 3866
diff changeset
    22
 * or visit www.oracle.com if you need additional information or have any
202f599c92aa 6943119: Rebrand source copyright notices
ohair
parents: 3866
diff changeset
    23
 * questions.
3059
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
    24
 */
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
    25
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
    26
package sun.net.www.http;
3866
34cd368bd2dd 6882384: Update http protocol handler to use PlatformLogger
chegar
parents: 3217
diff changeset
    27
3059
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
    28
import java.io.*;
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
    29
import java.util.ArrayList;
3866
34cd368bd2dd 6882384: Update http protocol handler to use PlatformLogger
chegar
parents: 3217
diff changeset
    30
import java.util.regex.*;
3059
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
    31
import sun.net.NetProperties;
3866
34cd368bd2dd 6882384: Update http protocol handler to use PlatformLogger
chegar
parents: 3217
diff changeset
    32
import sun.util.logging.PlatformLogger;
3059
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
    33
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
    34
/**
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
    35
 * Main class of the HTTP traffic capture tool.
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
    36
 * Captures are triggered by the sun.net.http.captureRules system property.
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
    37
 * If set, it should point to a file containing the capture rules.
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
    38
 * Format for the file is simple:
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
    39
 * - 1 rule per line
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
    40
 * - Lines starting with a # are considered comments and ignored
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
    41
 * - a rule is a pair of a regular expression and file pattern, separated by a comma
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
    42
 * - The regular expression is applied to URLs, if it matches, the traffic for
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
    43
 *   that URL will be captured in the associated file.
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
    44
 * - if the file name contains a '%d', then that sequence will be replaced by a
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
    45
 *   unique random number for each URL. This allow for multi-threaded captures
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
    46
 *   of URLs matching the same pattern.
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
    47
 * - Rules are checked in sequence, in the same order as in the file, until a
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
    48
 *   match is found or the end of the list is reached.
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
    49
 *
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
    50
 * Examples of rules:
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
    51
 * www\.sun\.com , sun%d.log
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
    52
 * yahoo\.com\/.*asf , yahoo.log
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
    53
 *
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
    54
 * @author jccollet
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
    55
 */
57968
8595871a5446 JDK-8229867: first prototype
dfuchs
parents: 47216
diff changeset
    56
// Using synchronized should be safe here.
3059
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
    57
public class HttpCapture {
34774
03b4e6dc367b 8145680: Remove unnecessary explicit initialization of volatile variables in java.base
redestad
parents: 29986
diff changeset
    58
    private File file;
3059
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
    59
    private boolean incoming = true;
34774
03b4e6dc367b 8145680: Remove unnecessary explicit initialization of volatile variables in java.base
redestad
parents: 29986
diff changeset
    60
    private BufferedWriter out;
03b4e6dc367b 8145680: Remove unnecessary explicit initialization of volatile variables in java.base
redestad
parents: 29986
diff changeset
    61
    private static boolean initialized;
03b4e6dc367b 8145680: Remove unnecessary explicit initialization of volatile variables in java.base
redestad
parents: 29986
diff changeset
    62
    private static volatile ArrayList<Pattern> patterns;
03b4e6dc367b 8145680: Remove unnecessary explicit initialization of volatile variables in java.base
redestad
parents: 29986
diff changeset
    63
    private static volatile ArrayList<String> capFiles;
3059
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
    64
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
    65
    private static synchronized void init() {
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
    66
        initialized = true;
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
    67
        String rulesFile = java.security.AccessController.doPrivileged(
29986
97167d851fc4 8078467: Update core libraries to use diamond with anonymous classes
darcy
parents: 25859
diff changeset
    68
            new java.security.PrivilegedAction<>() {
3059
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
    69
                public String run() {
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
    70
                    return NetProperties.get("sun.net.http.captureRules");
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
    71
                }
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
    72
            });
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
    73
        if (rulesFile != null && !rulesFile.isEmpty()) {
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
    74
            BufferedReader in;
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
    75
            try {
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
    76
                in = new BufferedReader(new FileReader(rulesFile));
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
    77
            } catch (FileNotFoundException ex) {
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
    78
                return;
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
    79
            }
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
    80
            try {
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
    81
                String line = in.readLine();
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
    82
                while (line != null) {
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
    83
                    line = line.trim();
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
    84
                    if (!line.startsWith("#")) {
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
    85
                        // skip line if it's a comment
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
    86
                        String[] s = line.split(",");
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
    87
                        if (s.length == 2) {
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
    88
                            if (patterns == null) {
29986
97167d851fc4 8078467: Update core libraries to use diamond with anonymous classes
darcy
parents: 25859
diff changeset
    89
                                patterns = new ArrayList<>();
97167d851fc4 8078467: Update core libraries to use diamond with anonymous classes
darcy
parents: 25859
diff changeset
    90
                                capFiles = new ArrayList<>();
3059
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
    91
                            }
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
    92
                            patterns.add(Pattern.compile(s[0].trim()));
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
    93
                            capFiles.add(s[1].trim());
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
    94
                        }
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
    95
                    }
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
    96
                    line = in.readLine();
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
    97
                }
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
    98
            } catch (IOException ioe) {
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
    99
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
   100
            } finally {
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
   101
                try {
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
   102
                    in.close();
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
   103
                } catch (IOException ex) {
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
   104
                }
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
   105
            }
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
   106
        }
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
   107
    }
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
   108
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
   109
    private static synchronized boolean isInitialized() {
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
   110
        return initialized;
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
   111
    }
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
   112
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
   113
    private HttpCapture(File f, java.net.URL url) {
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
   114
        file = f;
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
   115
        try {
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
   116
            out = new BufferedWriter(new FileWriter(file, true));
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
   117
            out.write("URL: " + url + "\n");
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
   118
        } catch (IOException ex) {
3866
34cd368bd2dd 6882384: Update http protocol handler to use PlatformLogger
chegar
parents: 3217
diff changeset
   119
            PlatformLogger.getLogger(HttpCapture.class.getName()).severe(null, ex);
3059
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
   120
        }
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
   121
    }
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
   122
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
   123
    public synchronized void sent(int c) throws IOException {
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
   124
        if (incoming) {
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
   125
            out.write("\n------>\n");
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
   126
            incoming = false;
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
   127
            out.flush();
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
   128
        }
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
   129
        out.write(c);
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
   130
    }
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
   131
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
   132
    public synchronized void received(int c) throws IOException {
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
   133
        if (!incoming) {
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
   134
            out.write("\n<------\n");
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
   135
            incoming = true;
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
   136
            out.flush();
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
   137
        }
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
   138
        out.write(c);
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
   139
    }
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
   140
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
   141
    public synchronized void flush() throws IOException {
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
   142
        out.flush();
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
   143
    }
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
   144
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
   145
    public static HttpCapture getCapture(java.net.URL url) {
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
   146
        if (!isInitialized()) {
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
   147
            init();
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
   148
        }
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
   149
        if (patterns == null || patterns.isEmpty()) {
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
   150
            return null;
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
   151
        }
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
   152
        String s = url.toString();
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
   153
        for (int i = 0; i < patterns.size(); i++) {
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
   154
            Pattern p = patterns.get(i);
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
   155
            if (p.matcher(s).find()) {
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
   156
                String f = capFiles.get(i);
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
   157
                File fi;
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
   158
                if (f.indexOf("%d") >= 0) {
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
   159
                    java.util.Random rand = new java.util.Random();
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
   160
                    do {
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
   161
                        String f2 = f.replace("%d", Integer.toString(rand.nextInt()));
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
   162
                        fi = new File(f2);
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
   163
                    } while (fi.exists());
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
   164
                } else {
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
   165
                    fi = new File(f);
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
   166
                }
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
   167
                return new HttpCapture(fi, url);
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
   168
            }
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
   169
        }
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
   170
        return null;
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
   171
    }
2975ff687a6b 6811297: Add more logging to HTTP protocol handler
jccollet
parents:
diff changeset
   172
}