1 /**************************************************************************/
2 /*                                                                        */
3 /*       Copyright (c) Microsoft Corporation. All rights reserved.        */
4 /*                                                                        */
5 /*       This software is licensed under the Microsoft Software License   */
6 /*       Terms for Microsoft Azure RTOS. Full text of the license can be  */
7 /*       found in the LICENSE file at https://aka.ms/AzureRTOS_EULA       */
8 /*       and in the root directory of this software.                      */
9 /*                                                                        */
10 /**************************************************************************/
11 
12 
13 /**************************************************************************/
14 /**************************************************************************/
15 /**                                                                       */
16 /** NetX Duo Component                                                    */
17 /**                                                                       */
18 /**   File Transfer Protocol (FTP)                                        */
19 /**                                                                       */
20 /**************************************************************************/
21 /**************************************************************************/
22 
23 
24 /**************************************************************************/
25 /*                                                                        */
26 /*  APPLICATION INTERFACE DEFINITION                       RELEASE        */
27 /*                                                                        */
28 /*    nxd_ftp_client.h                                    PORTABLE C      */
29 /*                                                           6.1.9        */
30 /*  AUTHOR                                                                */
31 /*                                                                        */
32 /*    Yuxin Zhou, Microsoft Corporation                                   */
33 /*                                                                        */
34 /*  DESCRIPTION                                                           */
35 /*                                                                        */
36 /*    This file defines the NetX Duo File Transfer Protocol (FTP over     */
37 /*    IPv6) component, including all data types and external references.  */
38 /*    It is assumed that nx_api.h and nx_port.h have already been         */
39 /*    included, along with fx_api.h and fx_port.h.                        */
40 /*                                                                        */
41 /*  RELEASE HISTORY                                                       */
42 /*                                                                        */
43 /*    DATE              NAME                      DESCRIPTION             */
44 /*                                                                        */
45 /*  05-19-2020     Yuxin Zhou               Initial Version 6.0           */
46 /*  09-30-2020     Yuxin Zhou               Modified comment(s),          */
47 /*                                            resulting in version 6.1    */
48 /*  10-15-2021     Yuxin Zhou               Modified comment(s), included */
49 /*                                            necessary header file,      */
50 /*                                            resulting in version 6.1.9  */
51 /*                                                                        */
52 /**************************************************************************/
53 
54 #ifndef NXD_FTP_CLIENT_H
55 #define NXD_FTP_CLIENT_H
56 
57 /* Determine if a C++ compiler is being used.  If so, ensure that standard
58    C is used to process the API information.  */
59 
60 #ifdef   __cplusplus
61 
62 /* Yes, C++ compiler is present.  Use standard C.  */
63 extern   "C" {
64 
65 #endif
66 
67 #include "nx_api.h"
68 
69 
70 /* Define the FTP Client ID.  */
71 
72 
73 #define NXD_FTP_CLIENT_ID                           0x46545200UL
74 
75 
76 /* Define the maximum number of clients the FTP Server can accommodate.  */
77 
78 #ifndef NX_FTP_MAX_CLIENTS
79 #define NX_FTP_MAX_CLIENTS                  4
80 #endif
81 
82 
83 /* Define FTP TCP socket create options.  Normally any TCP port will do but this
84    gives the application a means to specify a source port.  */
85 
86 #ifndef NX_FTP_CLIENT_SOURCE_PORT
87 #define NX_FTP_CLIENT_SOURCE_PORT           NX_ANY_PORT
88 #endif
89 
90 #ifndef NX_FTP_CONTROL_TOS
91 #define NX_FTP_CONTROL_TOS                  NX_IP_NORMAL
92 #endif
93 
94 #ifndef NX_FTP_DATA_TOS
95 #define NX_FTP_DATA_TOS                     NX_IP_NORMAL
96 #endif
97 
98 #ifndef NX_FTP_FRAGMENT_OPTION
99 #define NX_FTP_FRAGMENT_OPTION              NX_DONT_FRAGMENT
100 #endif
101 
102 #ifndef NX_FTP_CONTROL_WINDOW_SIZE
103 #define NX_FTP_CONTROL_WINDOW_SIZE          400
104 #endif
105 
106 #ifndef NX_FTP_DATA_WINDOW_SIZE
107 #define NX_FTP_DATA_WINDOW_SIZE             2048
108 #endif
109 
110 
111 #ifndef NX_FTP_TIME_TO_LIVE
112 #define NX_FTP_TIME_TO_LIVE                 0x80
113 #endif
114 
115 #ifndef NX_FTP_USERNAME_SIZE
116 #define NX_FTP_USERNAME_SIZE                20
117 #endif
118 
119 #ifndef NX_FTP_PASSWORD_SIZE
120 #define NX_FTP_PASSWORD_SIZE                20
121 #endif
122 
123 #ifndef NX_FTP_TIMEOUT_PERIOD
124 #define NX_FTP_TIMEOUT_PERIOD               60          /* Number of seconds to check                          */
125 #endif
126 
127 
128 
129 /* Define open types.  */
130 
131 #define NX_FTP_OPEN_FOR_READ                0x01        /* FTP file open for reading                           */
132 #define NX_FTP_OPEN_FOR_WRITE               0x02        /* FTP file open for writing                           */
133 
134 
135 /* Define transfer modes. Note: just support stream mode and block mode yet.  */
136 
137 #define NX_FTP_TRANSFER_MODE_STREAM         0           /* FTP stream transmission mode                        */
138 #define NX_FTP_TRANSFER_MODE_BLOCK          1           /* FTP block transmission mode                         */
139 #define NX_FTP_TRANSFER_MODE_COMPRESSED     2           /* FTP compressed transmission mode                    */
140 
141 
142 /* Define return code constants.  */
143 
144 #define NX_FTP_ERROR                        0xD0        /* Generic FTP internal error - deprecated             */
145 #define NX_FTP_TIMEOUT                      0xD1        /* FTP timeout occurred                                */
146 #define NX_FTP_FAILED                       0xD2        /* FTP error                                           */
147 #define NX_FTP_NOT_CONNECTED                0xD3        /* FTP not connected error                             */
148 #define NX_FTP_NOT_DISCONNECTED             0xD4        /* FTP not disconnected error                          */
149 #define NX_FTP_NOT_OPEN                     0xD5        /* FTP not opened error                                */
150 #define NX_FTP_NOT_CLOSED                   0xD6        /* FTP not closed error                                */
151 #define NX_FTP_END_OF_FILE                  0xD7        /* FTP end of file status                              */
152 #define NX_FTP_END_OF_LISTING               0xD8        /* FTP end of directory listing status                 */
153 #define NX_FTP_EXPECTED_1XX_CODE            0xD9        /* Expected a 1xx response from server                 */
154 #define NX_FTP_EXPECTED_2XX_CODE            0xDA        /* Expected a 2xx response from server                 */
155 #define NX_FTP_EXPECTED_22X_CODE            0xDB        /* Expected a 22x response from server                 */
156 #define NX_FTP_EXPECTED_23X_CODE            0xDC        /* Expected a 23x response from server                 */
157 #define NX_FTP_EXPECTED_3XX_CODE            0xDD        /* Expected a 3xx response from server                 */
158 #define NX_FTP_EXPECTED_33X_CODE            0xDE        /* Expected a 33x response from server                 */
159 #define NX_FTP_INVALID_NUMBER               0xDF        /* Extraced an invalid number from server response     */
160 #define NX_FTP_INVALID_ADDRESS              0x1D0       /* Invalid IP address parsed from FTP command          */
161 #define NX_FTP_INVALID_COMMAND              0x1D1       /* Invalid FTP command (bad syntax, unknown command)   */
162 #define NX_FTP_CLIENT_INVALID_SIZE          0x1D2       /* Invalid FTP file size                               */
163 #define NX_FTP_CLIENT_FILE_SIZE_ALREADY_SET 0x1D3       /* The file size is already set                        */
164 #define NX_FTP_CLIENT_NOT_BLOCK_MODE        0x1D4       /* Block mode is not enabled                           */
165 #define NX_FTP_CLIENT_END_OF_BLOCK          0x1D5       /* FTP end of block                                    */
166 
167 
168 /* Define FTP connection states.  */
169 
170 #define NX_FTP_STATE_NOT_CONNECTED          1           /* FTP not connected                                   */
171 #define NX_FTP_STATE_CONNECTED              2           /* FTP connected                                       */
172 #define NX_FTP_STATE_OPEN                   3           /* FTP file open for reading                           */
173 #define NX_FTP_STATE_WRITE_OPEN             4           /* FTP file open for writing                           */
174 
175 
176 /* Define the FTP Server TCP port numbers.  */
177 
178 #define NX_FTP_SERVER_CONTROL_PORT          21          /* Control Port for FTP server                         */
179 #define NX_FTP_SERVER_DATA_PORT             20          /* Data Port for FTP server in active transfer mode    */
180 
181 /* Define the size for buffer to store an IPv6 address represented in ASCII. */
182 #define NX_FTP_IPV6_ADDRESS_BUFSIZE         60
183 
184 /* Define the FTP basic commands.  The ASCII command will be parsed and converted to the numerical
185    representation shown below.  */
186 
187 #define NX_FTP_NOOP                         0
188 #define NX_FTP_USER                         1
189 #define NX_FTP_PASS                         2
190 #define NX_FTP_QUIT                         3
191 #define NX_FTP_RETR                         4
192 #define NX_FTP_STOR                         5
193 #define NX_FTP_RNFR                         6
194 #define NX_FTP_RNTO                         7
195 #define NX_FTP_DELE                         8
196 #define NX_FTP_RMD                          9
197 #define NX_FTP_MKD                          10
198 #define NX_FTP_NLST                         11
199 #define NX_FTP_PORT                         12
200 #define NX_FTP_CWD                          13
201 #define NX_FTP_PWD                          14
202 #define NX_FTP_TYPE                         15
203 #define NX_FTP_LIST                         16
204 #define NX_FTP_CDUP                         17
205 #define NX_FTP_INVALID                      18
206 #define NX_FTP_EPRT                         19
207 #define NX_FTP_PASV                         20
208 #define NX_FTP_EPSV                         21
209 #define NX_FTP_MODE                         22
210 
211 
212 
213 /* Define the basic FTP Client data structure.  */
214 
215 typedef struct NX_FTP_CLIENT_STRUCT
216 {
217     ULONG           nx_ftp_client_id;                               /* FTP Client ID                       */
218     CHAR           *nx_ftp_client_name;                             /* Name of this FTP client             */
219     NX_IP          *nx_ftp_client_ip_ptr;                           /* Pointer to associated IP structure  */
220     NX_PACKET_POOL *nx_ftp_client_packet_pool_ptr;                  /* Pointer to FTP client packet pool   */
221     ULONG           nx_ftp_client_server_ip;                        /* Server's IP address                 */
222     UINT            nx_ftp_client_state;                            /* State of FTP client                 */
223     NX_TCP_SOCKET   nx_ftp_client_control_socket;                   /* Client FTP control socket           */
224     NX_TCP_SOCKET   nx_ftp_client_data_socket;                      /* Client FTP data transfer socket     */
225     UINT            nx_ftp_client_data_port;                        /* Port the Client data socket binds   */
226     UINT            nx_ftp_client_passive_transfer_enabled;         /* Client enabled for passive transfer */
227     UINT            nx_ftp_client_transfer_mode;                    /* Client transfer mode                */
228     ULONG           nx_ftp_client_block_total_size;                 /* Total size of data in block mode    */
229     ULONG           nx_ftp_client_block_remaining_size;             /* Remaining size of data in block mode*/
230 } NX_FTP_CLIENT;
231 
232 
233 #ifndef NX_FTP_SOURCE_CODE
234 
235 /* Application caller is present, perform API mapping.  */
236 
237 /* Determine if error checking is desired.  If so, map API functions
238    to the appropriate error checking front-ends.  Otherwise, map API
239    functions to the core functions that actually perform the work.
240    Note: error checking is enabled by default.  */
241 
242 #ifdef NX_DISABLE_ERROR_CHECKING
243 
244 /* Services without error checking.  */
245 
246 #define nx_ftp_client_connect                       _nx_ftp_client_connect
247 #define nxd_ftp_client_connect                      _nxd_ftp_client_connect
248 #define nx_ftp_client_create                        _nx_ftp_client_create
249 #define nx_ftp_client_delete                        _nx_ftp_client_delete
250 #define nx_ftp_client_directory_create              _nx_ftp_client_directory_create
251 #define nx_ftp_client_directory_default_set         _nx_ftp_client_directory_default_set
252 #define nx_ftp_client_directory_delete              _nx_ftp_client_directory_delete
253 #define nx_ftp_client_directory_listing_get         _nx_ftp_client_directory_listing_get
254 #define nx_ftp_client_directory_listing_continue    _nx_ftp_client_directory_listing_continue
255 #define nx_ftp_client_disconnect                    _nx_ftp_client_disconnect
256 #define nx_ftp_client_file_close                    _nx_ftp_client_file_close
257 #define nx_ftp_client_file_delete                   _nx_ftp_client_file_delete
258 #define nx_ftp_client_file_open                     _nx_ftp_client_file_open
259 #define nx_ftp_client_file_read                     _nx_ftp_client_file_read
260 #define nx_ftp_client_file_rename                   _nx_ftp_client_file_rename
261 #define nx_ftp_client_file_write                    _nx_ftp_client_file_write
262 #define nx_ftp_client_file_size_set                 _nx_ftp_client_file_size_set
263 #define nx_ftp_client_passive_mode_set              _nx_ftp_client_passive_mode_set
264 #define nx_ftp_client_transfer_mode_set             _nx_ftp_client_transfer_mode_set
265 
266 #else
267 
268 /* Services with error checking.  */
269 
270 #define nx_ftp_client_connect                       _nxe_ftp_client_connect
271 #define nxd_ftp_client_connect                      _nxde_ftp_client_connect
272 #define nx_ftp_client_create                        _nxe_ftp_client_create
273 #define nx_ftp_client_delete                        _nxe_ftp_client_delete
274 #define nx_ftp_client_directory_create              _nxe_ftp_client_directory_create
275 #define nx_ftp_client_directory_default_set         _nxe_ftp_client_directory_default_set
276 #define nx_ftp_client_directory_delete              _nxe_ftp_client_directory_delete
277 #define nx_ftp_client_directory_listing_get         _nxe_ftp_client_directory_listing_get
278 #define nx_ftp_client_directory_listing_continue    _nxe_ftp_client_directory_listing_continue
279 #define nx_ftp_client_disconnect                    _nxe_ftp_client_disconnect
280 #define nx_ftp_client_file_close                    _nxe_ftp_client_file_close
281 #define nx_ftp_client_file_delete                   _nxe_ftp_client_file_delete
282 #define nx_ftp_client_file_open                     _nxe_ftp_client_file_open
283 #define nx_ftp_client_file_read                     _nxe_ftp_client_file_read
284 #define nx_ftp_client_file_rename                   _nxe_ftp_client_file_rename
285 #define nx_ftp_client_file_write                    _nxe_ftp_client_file_write
286 #define nx_ftp_client_file_size_set                 _nxe_ftp_client_file_size_set
287 #define nx_ftp_client_passive_mode_set              _nxe_ftp_client_passive_mode_set
288 #define nx_ftp_client_transfer_mode_set             _nxe_ftp_client_transfer_mode_set
289 
290 #endif
291 
292 /* Define the prototypes accessible to the application software.  */
293 
294 UINT        nx_ftp_client_connect(NX_FTP_CLIENT *ftp_client_ptr, ULONG server_ip, CHAR *username, CHAR *password, ULONG wait_option);
295 UINT        nxd_ftp_client_connect(NX_FTP_CLIENT *ftp_client_ptr, NXD_ADDRESS *server_ipduo, CHAR *username, CHAR *password, ULONG wait_option);
296 UINT        nx_ftp_client_create(NX_FTP_CLIENT *ftp_client_ptr, CHAR *ftp_client_name, NX_IP *ip_ptr, ULONG window_size, NX_PACKET_POOL *pool_ptr);
297 UINT        nx_ftp_client_delete(NX_FTP_CLIENT *ftp_client_ptr);
298 UINT        nx_ftp_client_directory_create(NX_FTP_CLIENT *ftp_client_ptr, CHAR *directory_name, ULONG wait_option);
299 UINT        nx_ftp_client_directory_default_set(NX_FTP_CLIENT *ftp_client_ptr, CHAR *directory_path, ULONG wait_option);
300 UINT        nx_ftp_client_directory_delete(NX_FTP_CLIENT *ftp_client_ptr, CHAR *directory_name, ULONG wait_option);
301 UINT        nx_ftp_client_directory_listing_get(NX_FTP_CLIENT *ftp_client_ptr, CHAR *directory_path, NX_PACKET **packet_ptr, ULONG wait_option);
302 UINT        nx_ftp_client_directory_listing_continue(NX_FTP_CLIENT *ftp_client_ptr, NX_PACKET **packet_ptr, ULONG wait_option);
303 UINT        nx_ftp_client_disconnect(NX_FTP_CLIENT *ftp_client_ptr, ULONG wait_option);
304 UINT        nx_ftp_client_file_close(NX_FTP_CLIENT *ftp_client_ptr, ULONG wait_option);
305 UINT        nx_ftp_client_file_delete(NX_FTP_CLIENT *ftp_client_ptr, CHAR *file_name, ULONG wait_option);
306 UINT        nx_ftp_client_file_open(NX_FTP_CLIENT *ftp_client_ptr, CHAR *file_name, UINT open_type, ULONG wait_option);
307 UINT        nx_ftp_client_file_read(NX_FTP_CLIENT *ftp_client_ptr, NX_PACKET **packet_ptr, ULONG wait_option);
308 UINT        nx_ftp_client_file_rename(NX_FTP_CLIENT *ftp_ptr, CHAR *filename, CHAR *new_filename, ULONG wait_option);
309 UINT        nx_ftp_client_file_write(NX_FTP_CLIENT *ftp_client_ptr, NX_PACKET *packet_ptr, ULONG wait_option);
310 UINT        nx_ftp_client_file_size_set(NX_FTP_CLIENT *ftp_client_ptr, ULONG file_size);
311 UINT        nx_ftp_client_passive_mode_set(NX_FTP_CLIENT *ftp_client_ptr, UINT passive_mode_enabled);
312 UINT        nx_ftp_client_transfer_mode_set(NX_FTP_CLIENT *ftp_client_ptr, UINT transfer_mode);
313 
314 #else
315 
316 /* FTP source code is being compiled, do not perform any API mapping.  */
317 
318 UINT        _nxe_ftp_client_connect(NX_FTP_CLIENT *ftp_client_ptr, ULONG server_ip, CHAR *username, CHAR *password, ULONG wait_option);
319 UINT        _nx_ftp_client_connect(NX_FTP_CLIENT *ftp_client_ptr, ULONG server_ip, CHAR *username, CHAR *password, ULONG wait_option);
320 UINT        _nxde_ftp_client_connect(NX_FTP_CLIENT *ftp_client_ptr, NXD_ADDRESS *server_ipduo, CHAR *username, CHAR *password, ULONG wait_option);
321 UINT        _nxd_ftp_client_connect(NX_FTP_CLIENT *ftp_client_ptr, NXD_ADDRESS *server_ipduo, CHAR *username, CHAR *password, ULONG wait_option);
322 UINT        _nxe_ftp_client_create(NX_FTP_CLIENT *ftp_client_ptr, CHAR *ftp_client_name, NX_IP *ip_ptr, ULONG window_size, NX_PACKET_POOL *pool_ptr);
323 UINT        _nx_ftp_client_create(NX_FTP_CLIENT *ftp_client_ptr, CHAR *ftp_client_name, NX_IP *ip_ptr, ULONG window_size, NX_PACKET_POOL *pool_ptr);
324 UINT        _nxe_ftp_client_delete(NX_FTP_CLIENT *ftp_client_ptr);
325 UINT        _nx_ftp_client_delete(NX_FTP_CLIENT *ftp_client_ptr);
326 UINT        _nxe_ftp_client_directory_create(NX_FTP_CLIENT *ftp_client_ptr, CHAR *directory_name, ULONG wait_option);
327 UINT        _nx_ftp_client_directory_create(NX_FTP_CLIENT *ftp_client_ptr, CHAR *directory_name, ULONG wait_option);
328 UINT        _nxe_ftp_client_directory_default_set(NX_FTP_CLIENT *ftp_client_ptr, CHAR *directory_path, ULONG wait_option);
329 UINT        _nx_ftp_client_directory_default_set(NX_FTP_CLIENT *ftp_client_ptr, CHAR *directory_path, ULONG wait_option);
330 UINT        _nxe_ftp_client_directory_delete(NX_FTP_CLIENT *ftp_client_ptr, CHAR *directory_name, ULONG wait_option);
331 UINT        _nx_ftp_client_directory_delete(NX_FTP_CLIENT *ftp_client_ptr, CHAR *directory_name, ULONG wait_option);
332 UINT        _nxe_ftp_client_directory_listing_get(NX_FTP_CLIENT *ftp_client_ptr, CHAR *directory_path, NX_PACKET **packet_ptr, ULONG wait_option);
333 UINT        _nx_ftp_client_directory_listing_get(NX_FTP_CLIENT *ftp_client_ptr, CHAR *directory_path, NX_PACKET **packet_ptr, ULONG wait_option);
334 UINT        _nxe_ftp_client_directory_listing_continue(NX_FTP_CLIENT *ftp_client_ptr, NX_PACKET **packet_ptr, ULONG wait_option);
335 UINT        _nx_ftp_client_directory_listing_continue(NX_FTP_CLIENT *ftp_client_ptr, NX_PACKET **packet_ptr, ULONG wait_option);
336 UINT        _nxe_ftp_client_disconnect(NX_FTP_CLIENT *ftp_client_ptr, ULONG wait_option);
337 UINT        _nx_ftp_client_disconnect(NX_FTP_CLIENT *ftp_client_ptr, ULONG wait_option);
338 UINT        _nxe_ftp_client_file_close(NX_FTP_CLIENT *ftp_client_ptr, ULONG wait_option);
339 UINT        _nx_ftp_client_file_close(NX_FTP_CLIENT *ftp_client_ptr, ULONG wait_option);
340 UINT        _nxe_ftp_client_file_delete(NX_FTP_CLIENT *ftp_client_ptr, CHAR *file_name, ULONG wait_option);
341 UINT        _nx_ftp_client_file_delete(NX_FTP_CLIENT *ftp_client_ptr, CHAR *file_name, ULONG wait_option);
342 UINT        _nxe_ftp_client_file_open(NX_FTP_CLIENT *ftp_client_ptr, CHAR *file_name, UINT open_type, ULONG wait_option);
343 UINT        _nx_ftp_client_file_open(NX_FTP_CLIENT *ftp_client_ptr, CHAR *file_name, UINT open_type, ULONG wait_option);
344 UINT        _nxe_ftp_client_file_read(NX_FTP_CLIENT *ftp_client_ptr, NX_PACKET **packet_ptr, ULONG wait_option);
345 UINT        _nx_ftp_client_file_read(NX_FTP_CLIENT *ftp_client_ptr, NX_PACKET **packet_ptr, ULONG wait_option);
346 UINT        _nxe_ftp_client_file_rename(NX_FTP_CLIENT *ftp_client_ptr, CHAR *filename, CHAR *new_filename, ULONG wait_option);
347 UINT        _nx_ftp_client_file_rename(NX_FTP_CLIENT *ftp_ptr, CHAR *filename, CHAR *new_filename, ULONG wait_option);
348 UINT        _nxe_ftp_client_file_write(NX_FTP_CLIENT *ftp_client_ptr, NX_PACKET *packet_ptr, ULONG wait_option);
349 UINT        _nx_ftp_client_file_write(NX_FTP_CLIENT *ftp_client_ptr, NX_PACKET *packet_ptr, ULONG wait_option);
350 UINT        _nxe_ftp_client_file_size_set(NX_FTP_CLIENT *ftp_client_ptr, ULONG file_size);
351 UINT        _nx_ftp_client_file_size_set(NX_FTP_CLIENT *ftp_client_ptr, ULONG file_size);
352 UINT        _nxe_ftp_client_passive_mode_set(NX_FTP_CLIENT *ftp_client_ptr, UINT passive_mode_enabled);
353 UINT        _nx_ftp_client_passive_mode_set(NX_FTP_CLIENT *ftp_client_ptr, UINT passive_mode_enabled);
354 UINT        _nxe_ftp_client_transfer_mode_set(NX_FTP_CLIENT *ftp_client_ptr, UINT transfer_mode);
355 UINT        _nx_ftp_client_transfer_mode_set(NX_FTP_CLIENT *ftp_client_ptr, UINT transfer_mode);
356 
357 #endif   /* NX_FTP_SOURCE_CODE */
358 
359 /* Internal functions. */
360 VOID        _nx_ftp_client_data_disconnect(NX_TCP_SOCKET *data_socket_ptr);
361 UINT        _nx_ftp_client_packet_allocate(NX_FTP_CLIENT *ftp_client_ptr, NX_PACKET **packet_ptr, ULONG wait_option);
362 UINT        _nx_ftp_client_active_transfer_setup(NX_FTP_CLIENT *ftp_client_ptr, ULONG wait_option);
363 UINT        _nx_ftp_client_passive_transfer_setup(NX_FTP_CLIENT *ftp_client_ptr, ULONG wait_option);
364 VOID        _nx_ftp_client_data_socket_cleanup(NX_FTP_CLIENT *ftp_client_ptr, ULONG wait_option);
365 UINT        _nx_ftp_client_block_mode_send(NX_FTP_CLIENT *ftp_client_ptr, ULONG wait_option);
366 UINT        _nx_ftp_client_block_header_send(NX_FTP_CLIENT *ftp_client_ptr, ULONG block_size);
367 UINT        _nx_ftp_client_block_header_retrieve(NX_FTP_CLIENT *ftp_client_ptr, NX_PACKET *packet_ptr);
368 UINT        _nx_ftp_client_connect_internal(NX_FTP_CLIENT *ftp_client_ptr, NXD_ADDRESS *server_ip, CHAR *username, CHAR *password, ULONG wait_option);
369 UINT        _nx_ftp_utility_convert_IPv6_to_ascii(NX_TCP_SOCKET *tcp_socket_ptr, CHAR *buffer, UINT buffer_length, UINT *size);
370 UINT        _nx_ftp_utility_convert_number_ascii(ULONG number, CHAR *numstring);
371 UINT        _nx_ftp_utility_convert_portnumber_ascii(UINT number, CHAR *numstring, UINT *numstring_length);
372 
373 
374 /* Determine if a C++ compiler is being used.  If so, complete the standard
375    C conditional started above.  */
376 #ifdef   __cplusplus
377         }
378 #endif
379 
380 #endif  /* NXD_FTP_CLIENT_H */
381