Skip to content

Commit ccc22de

Browse files
committed
Initial implementation of FTP protocol
1 parent 84ee193 commit ccc22de

17 files changed

+1628
-829
lines changed

Foundation.xcodeproj/project.pbxproj

Lines changed: 35 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -303,9 +303,12 @@
303303
5FE52C951D147D1C00F7D270 /* TestNSTextCheckingResult.swift in Sources */ = {isa = PBXBuildFile; fileRef = 5FE52C941D147D1C00F7D270 /* TestNSTextCheckingResult.swift */; };
304304
61E0117D1C1B5590000037DD /* RunLoop.swift in Sources */ = {isa = PBXBuildFile; fileRef = EADE0B761BD15DFF00C49C64 /* RunLoop.swift */; };
305305
61E0117E1C1B55B9000037DD /* Timer.swift in Sources */ = {isa = PBXBuildFile; fileRef = 5BDC3F481BCC5DCB00ED97BB /* Timer.swift */; };
306+
617F57F31F1F5CD30004F3F0 /* FTPURLProtocol.swift in Sources */ = {isa = PBXBuildFile; fileRef = 617F57F21F1F5CD30004F3F0 /* FTPURLProtocol.swift */; };
307+
61827A9E1F2208E400016214 /* FTPServer.swift in Sources */ = {isa = PBXBuildFile; fileRef = 61827A9D1F2208E400016214 /* FTPServer.swift */; };
306308
61E0117F1C1B5990000037DD /* CFRunLoop.c in Sources */ = {isa = PBXBuildFile; fileRef = 5B5D88D81BBC9AD800234F36 /* CFRunLoop.c */; };
307309
61E011811C1B5998000037DD /* CFMessagePort.c in Sources */ = {isa = PBXBuildFile; fileRef = 5B5D88DC1BBC9AEC00234F36 /* CFMessagePort.c */; };
308310
61E011821C1B599A000037DD /* CFMachPort.c in Sources */ = {isa = PBXBuildFile; fileRef = 5B5D88D01BBC9AAC00234F36 /* CFMachPort.c */; };
311+
61EE04551F208805002051A2 /* NativeProtocol.swift in Sources */ = {isa = PBXBuildFile; fileRef = 61EE04541F208805002051A2 /* NativeProtocol.swift */; };
309312
63DCE9D21EAA430100E9CB02 /* ISO8601DateFormatter.swift in Sources */ = {isa = PBXBuildFile; fileRef = 63DCE9D11EAA430100E9CB02 /* ISO8601DateFormatter.swift */; };
310313
63DCE9D41EAA432400E9CB02 /* TestISO8601DateFormatter.swift in Sources */ = {isa = PBXBuildFile; fileRef = 63DCE9D31EAA432400E9CB02 /* TestISO8601DateFormatter.swift */; };
311314
6EB768281D18C12C00D4B719 /* UUID.swift in Sources */ = {isa = PBXBuildFile; fileRef = 6EB768271D18C12C00D4B719 /* UUID.swift */; };
@@ -323,7 +326,6 @@
323326
B910957B1EEF237800A71930 /* NSString-UTF16-BE-data.txt in Resources */ = {isa = PBXBuildFile; fileRef = B91095791EEF237800A71930 /* NSString-UTF16-BE-data.txt */; };
324327
B933A79E1F3055F700FE6846 /* NSString-UTF32-BE-data.txt in Resources */ = {isa = PBXBuildFile; fileRef = B933A79C1F3055F600FE6846 /* NSString-UTF32-BE-data.txt */; };
325328
B933A79F1F3055F700FE6846 /* NSString-UTF32-LE-data.txt in Resources */ = {isa = PBXBuildFile; fileRef = B933A79D1F3055F600FE6846 /* NSString-UTF32-LE-data.txt */; };
326-
B9974B961EDF4A22007F15B8 /* TransferState.swift in Sources */ = {isa = PBXBuildFile; fileRef = B9974B8F1EDF4A22007F15B8 /* TransferState.swift */; };
327329
B9974B971EDF4A22007F15B8 /* MultiHandle.swift in Sources */ = {isa = PBXBuildFile; fileRef = B9974B901EDF4A22007F15B8 /* MultiHandle.swift */; };
328330
B9974B981EDF4A22007F15B8 /* libcurlHelpers.swift in Sources */ = {isa = PBXBuildFile; fileRef = B9974B911EDF4A22007F15B8 /* libcurlHelpers.swift */; };
329331
B9974B991EDF4A22007F15B8 /* HTTPURLProtocol.swift in Sources */ = {isa = PBXBuildFile; fileRef = B9974B921EDF4A22007F15B8 /* HTTPURLProtocol.swift */; };
@@ -759,10 +761,13 @@
759761
5EB6A15C1C188FC40037DCB8 /* TestJSONSerialization.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = TestJSONSerialization.swift; sourceTree = "<group>"; };
760762
5EF673AB1C28B527006212A3 /* TestNotificationQueue.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = TestNotificationQueue.swift; sourceTree = "<group>"; };
761763
5FE52C941D147D1C00F7D270 /* TestNSTextCheckingResult.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = TestNSTextCheckingResult.swift; sourceTree = "<group>"; };
764+
617F57F21F1F5CD30004F3F0 /* FTPURLProtocol.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = FTPURLProtocol.swift; sourceTree = "<group>"; };
765+
61827A9D1F2208E400016214 /* FTPServer.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = FTPServer.swift; sourceTree = "<group>"; };
762766
61A395F91C2484490029B337 /* TestNSLocale.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = TestNSLocale.swift; sourceTree = "<group>"; };
763767
61D6C9EE1C1DFE9500DEF583 /* TestTimer.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = TestTimer.swift; sourceTree = "<group>"; };
764768
61E0117B1C1B554D000037DD /* TestRunLoop.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = TestRunLoop.swift; sourceTree = "<group>"; };
765-
61F8AE7C1C180FC600FB62F0 /* TestNotificationCenter.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = TestNotificationCenter.swift; sourceTree = "<group>"; };
769+
61EE04541F208805002051A2 /* NativeProtocol.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = NativeProtocol.swift; sourceTree = "<group>"; };
770+
61F8AE7C1C180FC600FB62F0 /* TestNotificationCenter.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = TestNSNotificationCenter.swift; sourceTree = "<group>"; };
766771
63DCE9D11EAA430100E9CB02 /* ISO8601DateFormatter.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = ISO8601DateFormatter.swift; sourceTree = "<group>"; };
767772
63DCE9D31EAA432400E9CB02 /* TestISO8601DateFormatter.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = TestISO8601DateFormatter.swift; sourceTree = "<group>"; };
768773
6E203B8C1C1303BB003B2576 /* TestBundle.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = TestBundle.swift; sourceTree = "<group>"; };
@@ -789,13 +794,12 @@
789794
B91095791EEF237800A71930 /* NSString-UTF16-BE-data.txt */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; path = "NSString-UTF16-BE-data.txt"; sourceTree = "<group>"; };
790795
B933A79C1F3055F600FE6846 /* NSString-UTF32-BE-data.txt */ = {isa = PBXFileReference; lastKnownFileType = text; path = "NSString-UTF32-BE-data.txt"; sourceTree = "<group>"; };
791796
B933A79D1F3055F600FE6846 /* NSString-UTF32-LE-data.txt */ = {isa = PBXFileReference; lastKnownFileType = text; path = "NSString-UTF32-LE-data.txt"; sourceTree = "<group>"; };
792-
B9974B8F1EDF4A22007F15B8 /* TransferState.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; name = TransferState.swift; path = http/TransferState.swift; sourceTree = "<group>"; };
793-
B9974B901EDF4A22007F15B8 /* MultiHandle.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; name = MultiHandle.swift; path = http/MultiHandle.swift; sourceTree = "<group>"; };
794-
B9974B911EDF4A22007F15B8 /* libcurlHelpers.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; name = libcurlHelpers.swift; path = http/libcurlHelpers.swift; sourceTree = "<group>"; };
797+
B9974B901EDF4A22007F15B8 /* MultiHandle.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = MultiHandle.swift; sourceTree = "<group>"; };
798+
B9974B911EDF4A22007F15B8 /* libcurlHelpers.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = libcurlHelpers.swift; sourceTree = "<group>"; };
795799
B9974B921EDF4A22007F15B8 /* HTTPURLProtocol.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; name = HTTPURLProtocol.swift; path = http/HTTPURLProtocol.swift; sourceTree = "<group>"; };
796800
B9974B931EDF4A22007F15B8 /* HTTPMessage.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; name = HTTPMessage.swift; path = http/HTTPMessage.swift; sourceTree = "<group>"; };
797801
B9974B941EDF4A22007F15B8 /* HTTPBodySource.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; name = HTTPBodySource.swift; path = http/HTTPBodySource.swift; sourceTree = "<group>"; };
798-
B9974B951EDF4A22007F15B8 /* EasyHandle.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; name = EasyHandle.swift; path = http/EasyHandle.swift; sourceTree = "<group>"; };
802+
B9974B951EDF4A22007F15B8 /* EasyHandle.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = EasyHandle.swift; sourceTree = "<group>"; };
799803
BD8042151E09857800487EB8 /* TestLengthFormatter.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = TestLengthFormatter.swift; sourceTree = "<group>"; };
800804
BDBB658F1E256BFA001A7286 /* TestEnergyFormatter.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = TestEnergyFormatter.swift; sourceTree = "<group>"; };
801805
BDFDF0A61DFF5B3E00C04CC5 /* TestPersonNameComponents.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = TestPersonNameComponents.swift; sourceTree = "<group>"; };
@@ -985,13 +989,16 @@
985989
5B1FD9C71D6D162D0080E83C /* Session */ = {
986990
isa = PBXGroup;
987991
children = (
992+
617F57F11F1F5C5F0004F3F0 /* ftp */,
993+
617F57F01F1F5C4B0004F3F0 /* libcurl */,
988994
E4F889331E9CF04D008A70EB /* http */,
989995
5B1FD9C81D6D16580080E83C /* Configuration.swift */,
990996
5B1FD9CE1D6D16580080E83C /* URLSession.swift */,
991997
5B1FD9CF1D6D16580080E83C /* URLSessionConfiguration.swift */,
992998
5B1FD9D01D6D16580080E83C /* URLSessionDelegate.swift */,
993999
5B1FD9D11D6D16580080E83C /* URLSessionTask.swift */,
9941000
5B1FD9D21D6D16580080E83C /* TaskRegistry.swift */,
1001+
61EE04541F208805002051A2 /* NativeProtocol.swift */,
9951002
);
9961003
name = Session;
9971004
path = URLSession;
@@ -1343,6 +1350,24 @@
13431350
path = Foundation;
13441351
sourceTree = "<group>";
13451352
};
1353+
617F57F01F1F5C4B0004F3F0 /* libcurl */ = {
1354+
isa = PBXGroup;
1355+
children = (
1356+
B9974B911EDF4A22007F15B8 /* libcurlHelpers.swift */,
1357+
B9974B951EDF4A22007F15B8 /* EasyHandle.swift */,
1358+
B9974B901EDF4A22007F15B8 /* MultiHandle.swift */,
1359+
);
1360+
path = libcurl;
1361+
sourceTree = "<group>";
1362+
};
1363+
617F57F11F1F5C5F0004F3F0 /* ftp */ = {
1364+
isa = PBXGroup;
1365+
children = (
1366+
617F57F21F1F5CD30004F3F0 /* FTPURLProtocol.swift */,
1367+
);
1368+
path = ftp;
1369+
sourceTree = "<group>";
1370+
};
13461371
9F4ADBCF1ECD4F56001F0B3D /* xdgTestHelper */ = {
13471372
isa = PBXGroup;
13481373
children = (
@@ -1357,12 +1382,8 @@
13571382
isa = PBXGroup;
13581383
children = (
13591384
B9974B921EDF4A22007F15B8 /* HTTPURLProtocol.swift */,
1360-
B9974B8F1EDF4A22007F15B8 /* TransferState.swift */,
1361-
B9974B901EDF4A22007F15B8 /* MultiHandle.swift */,
1362-
B9974B911EDF4A22007F15B8 /* libcurlHelpers.swift */,
13631385
B9974B931EDF4A22007F15B8 /* HTTPMessage.swift */,
13641386
B9974B941EDF4A22007F15B8 /* HTTPBodySource.swift */,
1365-
B9974B951EDF4A22007F15B8 /* EasyHandle.swift */,
13661387
);
13671388
name = http;
13681389
sourceTree = "<group>";
@@ -1381,6 +1402,7 @@
13811402
isa = PBXGroup;
13821403
children = (
13831404
1520469A1D8AEABE00D02E36 /* HTTPServer.swift */,
1405+
61827A9D1F2208E400016214 /* FTPServer.swift */,
13841406
EA66F6381BF1619600136161 /* main.swift */,
13851407
9F4ADBCF1ECD4F56001F0B3D /* xdgTestHelper */,
13861408
EA66F65A1BF1976100136161 /* Tests */,
@@ -2203,7 +2225,6 @@
22032225
EADE0BB31BD15E0000C49C64 /* NSRegularExpression.swift in Sources */,
22042226
EADE0BA41BD15E0000C49C64 /* LengthFormatter.swift in Sources */,
22052227
5BDC3FCA1BCF176100ED97BB /* NSCFArray.swift in Sources */,
2206-
B9974B961EDF4A22007F15B8 /* TransferState.swift in Sources */,
22072228
EADE0BB21BD15E0000C49C64 /* Progress.swift in Sources */,
22082229
EADE0B961BD15DFF00C49C64 /* DateIntervalFormatter.swift in Sources */,
22092230
5B5BFEAC1E6CC0C200AC8D9E /* NSCFBoolean.swift in Sources */,
@@ -2213,6 +2234,7 @@
22132234
EADE0BB81BD15E0000C49C64 /* Process.swift in Sources */,
22142235
5BF7AEB31BCD51F9008F214A /* NSObjCRuntime.swift in Sources */,
22152236
5BD31D3F1D5D19D600563814 /* Dictionary.swift in Sources */,
2237+
617F57F31F1F5CD30004F3F0 /* FTPURLProtocol.swift in Sources */,
22162238
B9974B9B1EDF4A22007F15B8 /* HTTPBodySource.swift in Sources */,
22172239
5B94E8821C430DE70055C035 /* NSStringAPI.swift in Sources */,
22182240
5B0163BB1D024EB7003CCD96 /* DateComponents.swift in Sources */,
@@ -2248,6 +2270,7 @@
22482270
EADE0BA61BD15E0000C49C64 /* MassFormatter.swift in Sources */,
22492271
5BECBA3A1D1CAE9A00B39B1F /* NSMeasurement.swift in Sources */,
22502272
5BF7AEB21BCD51F9008F214A /* NSNumber.swift in Sources */,
2273+
61EE04551F208805002051A2 /* NativeProtocol.swift in Sources */,
22512274
B9974B991EDF4A22007F15B8 /* HTTPURLProtocol.swift in Sources */,
22522275
5BCD03821D3EE35C00E3FF9B /* TimeZone.swift in Sources */,
22532276
EADE0BBC1BD15E0000C49C64 /* URLCache.swift in Sources */,
@@ -2413,6 +2436,7 @@
24132436
D5C40F331CDA1D460005690C /* TestOperationQueue.swift in Sources */,
24142437
BDBB65901E256BFA001A7286 /* TestEnergyFormatter.swift in Sources */,
24152438
5B13B32F1C582D4C00651CE2 /* TestNSGeometry.swift in Sources */,
2439+
61827A9E1F2208E400016214 /* FTPServer.swift in Sources */,
24162440
EA08126C1DA810BE00651B70 /* ProgressFraction.swift in Sources */,
24172441
5B13B3351C582D4C00651CE2 /* TestNSKeyedUnarchiver.swift in Sources */,
24182442
5B13B33D1C582D4C00651CE2 /* TestPipe.swift in Sources */,

0 commit comments

Comments
 (0)