2 * FreeRTOS+TCP V2.0.3
\r
3 * Copyright (C) 2017 Amazon.com, Inc. or its affiliates. All Rights Reserved.
\r
5 * Permission is hereby granted, free of charge, to any person obtaining a copy of
\r
6 * this software and associated documentation files (the "Software"), to deal in
\r
7 * the Software without restriction, including without limitation the rights to
\r
8 * use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
\r
9 * the Software, and to permit persons to whom the Software is furnished to do so,
\r
10 * subject to the following conditions:
\r
12 * The above copyright notice and this permission notice shall be included in all
\r
13 * copies or substantial portions of the Software.
\r
15 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
\r
16 * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
\r
17 * FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
\r
18 * COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
\r
19 * IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
\r
20 * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
\r
22 * http://aws.amazon.com/freertos
\r
23 * http://www.FreeRTOS.org
\r
26 /* FreeRTOS includes. */
\r
27 #include "FreeRTOS.h"
\r
29 /* FreeRTOS+TCP includes. */
\r
30 #include "FreeRTOS_FTP_commands.h"
\r
32 const FTPCommand_t xFTPCommands[ FTP_CMD_COUNT ] =
\r
34 /* cmdLen cmdName[7] cmdType checkLogin checkNullArg */
\r
35 { 4, "USER", ECMD_USER, pdFALSE, pdFALSE },
\r
36 { 4, "PASS", ECMD_PASS, pdFALSE, pdFALSE },
\r
37 { 4, "ACCT", ECMD_ACCT, pdTRUE, pdFALSE },
\r
38 { 3, "CWD", ECMD_CWD, pdTRUE, pdTRUE },
\r
39 { 4, "CDUP", ECMD_CDUP, pdTRUE, pdFALSE },
\r
40 { 4, "SMNT", ECMD_SMNT, pdTRUE, pdFALSE },
\r
41 { 4, "QUIT", ECMD_QUIT, pdTRUE, pdFALSE },
\r
42 { 4, "REIN", ECMD_REIN, pdTRUE, pdFALSE },
\r
43 { 4, "PORT", ECMD_PORT, pdTRUE, pdFALSE },
\r
44 { 4, "PASV", ECMD_PASV, pdTRUE, pdFALSE },
\r
45 { 4, "TYPE", ECMD_TYPE, pdTRUE, pdFALSE },
\r
46 { 4, "STRU", ECMD_STRU, pdTRUE, pdFALSE },
\r
47 { 4, "MODE", ECMD_MODE, pdTRUE, pdFALSE },
\r
48 { 4, "RETR", ECMD_RETR, pdTRUE, pdTRUE },
\r
49 { 4, "STOR", ECMD_STOR, pdTRUE, pdTRUE },
\r
50 { 4, "STOU", ECMD_STOU, pdTRUE, pdFALSE },
\r
51 { 4, "APPE", ECMD_APPE, pdTRUE, pdFALSE },
\r
52 { 4, "ALLO", ECMD_ALLO, pdTRUE, pdFALSE },
\r
53 { 4, "REST", ECMD_REST, pdTRUE, pdFALSE },
\r
54 { 4, "RNFR", ECMD_RNFR, pdTRUE, pdTRUE },
\r
55 { 4, "RNTO", ECMD_RNTO, pdTRUE, pdTRUE },
\r
56 { 4, "ABOR", ECMD_ABOR, pdTRUE, pdFALSE },
\r
57 { 4, "SIZE", ECMD_SIZE, pdTRUE, pdTRUE },
\r
58 { 4, "MDTM", ECMD_MDTM, pdTRUE, pdTRUE },
\r
59 { 4, "DELE", ECMD_DELE, pdTRUE, pdTRUE },
\r
60 { 3, "RMD", ECMD_RMD, pdTRUE, pdTRUE },
\r
61 { 3, "MKD", ECMD_MKD, pdTRUE, pdTRUE },
\r
62 { 3, "PWD", ECMD_PWD, pdTRUE, pdFALSE },
\r
63 { 4, "LIST", ECMD_LIST, pdTRUE, pdFALSE },
\r
64 { 4, "NLST", ECMD_NLST, pdTRUE, pdFALSE },
\r
65 { 4, "SITE", ECMD_SITE, pdTRUE, pdFALSE },
\r
66 { 4, "SYST", ECMD_SYST, pdFALSE, pdFALSE },
\r
67 { 4, "FEAT", ECMD_FEAT, pdFALSE, pdFALSE },
\r
68 { 4, "STAT", ECMD_STAT, pdTRUE, pdFALSE },
\r
69 { 4, "HELP", ECMD_HELP, pdFALSE, pdFALSE },
\r
70 { 4, "NOOP", ECMD_NOOP, pdFALSE, pdFALSE },
\r
71 { 4, "EMPT", ECMD_EMPTY, pdFALSE, pdFALSE },
\r
72 { 4, "CLOS", ECMD_CLOSE, pdTRUE, pdFALSE },
\r
73 { 4, "UNKN", ECMD_UNKNOWN, pdFALSE, pdFALSE },
\r