]>
Commit | Line | Data |
---|---|---|
bbc27441 AJ |
1 | /* |
2 | * Copyright (C) 1996-2014 The Squid Software Foundation and contributors | |
3 | * | |
4 | * Squid software is distributed under GPLv2+ license and includes | |
5 | * contributions from numerous individuals and organizations. | |
6 | * Please see the COPYING and CONTRIBUTORS files for details. | |
7 | */ | |
8 | ||
92ae4c86 AR |
9 | #ifndef SQUID_CLIENTS_FORWARD_H |
10 | #define SQUID_CLIENTS_FORWARD_H | |
11 | ||
12 | class FwdState; | |
13 | class HttpRequest; | |
14 | ||
5517260a AR |
15 | class AsyncJob; |
16 | template <class Cbc> class CbcPointer; | |
17 | typedef CbcPointer<AsyncJob> AsyncJobPointer; | |
18 | ||
27c841f6 AR |
19 | namespace Ftp |
20 | { | |
5517260a AR |
21 | |
22 | /// A new FTP Gateway job | |
23 | AsyncJobPointer StartGateway(FwdState *const fwdState); | |
24 | ||
25 | /// A new FTP Relay job | |
26 | AsyncJobPointer StartRelay(FwdState *const fwdState); | |
27 | ||
3cc0f4e7 AR |
28 | /** Construct an URI with leading / in PATH portion for use by CWD command |
29 | * possibly others. FTP encodes absolute paths as beginning with '/' | |
30 | * after the initial URI path delimiter, which happens to be / itself. | |
31 | * This makes FTP absolute URI appear as: ftp:host:port//root/path | |
32 | * To encompass older software which compacts multiple // to / in transit | |
33 | * We use standard URI-encoding on the second / making it | |
34 | * ftp:host:port/%2froot/path AKA 'the FTP %2f hack'. | |
35 | * | |
36 | * \todo Should be a URL class API call. | |
92ae4c86 | 37 | */ |
5517260a | 38 | const char *UrlWith2f(HttpRequest *); |
92ae4c86 | 39 | |
5517260a | 40 | } // namespace Ftp |
92ae4c86 AR |
41 | |
42 | #endif /* SQUID_CLIENTS_FORWARD_H */ | |
f53969cc | 43 |