diff --git a/client/Program.cs b/client/Program.cs new file mode 100644 index 00000000..0a8cc71b --- /dev/null +++ b/client/Program.cs @@ -0,0 +1,565 @@ +using System.Net; +using System.Net.Sockets; +using System.Text; +using System.Text.RegularExpressions; + + +Socket socket; +Socket data_socket; +Socket dataSocketListener; +string server; +int port; +bool active; +string user; +string password; +string path; + +// Funciones auxiliares +void SendCommand(string command) +{ + byte[] commandBytes = Encoding.ASCII.GetBytes(command + "\r\n"); + socket.Send(commandBytes); + // Console.WriteLine("Enviado: " + command); +} + +string ReceiveResponse() +{ + byte[] buffer = new byte[1024]; + int bytesReceived = socket.Receive(buffer); + return Encoding.ASCII.GetString(buffer, 0, bytesReceived); +} + +void SendData(Socket dataSocket, string filePath) + { + byte[] buffer = new byte[1024]; + using (FileStream fileStream = new FileStream(filePath, FileMode.Open, FileAccess.Read)) + { + int bytesRead; + while ((bytesRead = fileStream.Read(buffer, 0, buffer.Length)) > 0) + { + dataSocket.Send(buffer, bytesRead, SocketFlags.None); + } + } + } + +void Init(string _server, int _port, string _user, string _password){ + server = _server; + port = _port; + user = _user; + password = _password; + + active = true; + path = "/"; +} + +void SetActiveMode(){ + // 1. Crear un socket para escuchar las conexiones de datos entrantes + dataSocketListener = new Socket(AddressFamily.InterNetwork, SocketType.Stream, ProtocolType.Tcp); + IPEndPoint localEndPoint = new IPEndPoint(IPAddress.Any, 0); // Escucha en cualquier IP disponible y deja que el sistema operativo asigne un puerto + dataSocketListener.Bind(localEndPoint); + dataSocketListener.Listen(1); // Solo acepta una conexión + + active = true; + + // 2. Obtener la dirección IP y el puerto asignado + IPEndPoint dataEndpoint = (IPEndPoint)dataSocketListener.LocalEndPoint; + string ipAddress = GetLocalIPAddress(); // Método auxiliar para obtener la IP local + int port = dataEndpoint.Port; + + // 3. Formatear el comando PORT + Port(ipAddress, port); + + string GetLocalIPAddress(){ + Socket socket = new Socket(AddressFamily.InterNetwork, SocketType.Dgram, 0); + socket.Connect("8.8.8.8", 65530); + IPEndPoint endPoint = socket.LocalEndPoint as IPEndPoint; + return endPoint.Address.ToString(); + } +} + +void SetPassiveMode() + { + SendCommand("PASV"); + string response = ReceiveResponse(); + Console.WriteLine(response); + + active = false; + + int startIndex = response.IndexOf("(") + 1; + int endIndex = response.IndexOf(")"); + string data = response.Substring(startIndex, endIndex - startIndex); + + string[] parts = data.Split(','); + + //if (parts.Length == 6){ + string ipAddress = $"{parts[0]}.{parts[1]}.{parts[2]}.{parts[3]}"; + int port = int.Parse(parts[4]) * 256 + int.Parse(parts[5]); + + // Crear el socket de datos y conectarse + data_socket = new Socket(AddressFamily.InterNetwork, SocketType.Stream, ProtocolType.Tcp); + data_socket.Connect(ipAddress, port); + + Console.WriteLine($"Conectado al modo pasivo: {ipAddress}:{port}\n"); + //} + } + +string ReceiveData(Socket dataSocket) + { + StringBuilder sb = new StringBuilder(); + byte[] buffer = new byte[1024]; + int bytesRead; + + while ((bytesRead = dataSocket.Receive(buffer)) > 0) + { + sb.Append(Encoding.ASCII.GetString(buffer, 0, bytesRead)); + } + + return sb.ToString(); + } + +//Funciones Principales +void Connect(string _user, string _password) +{ + socket = new Socket(AddressFamily.InterNetwork, SocketType.Stream, ProtocolType.Tcp); + socket.Connect(server, port); + Console.WriteLine(ReceiveResponse()); //Recibe el mensaje de bienvenida + + user = _user; + password = _password; + + SendCommand("USER " + user); + // Console.WriteLine(ReceiveResponse()); + ReceiveResponse(); + + SendCommand("PASS " + password); + Console.WriteLine(ReceiveResponse()); +} + +//No disponible en FreeFTPd +void Reinitialize(){ + Init(server, port, user, password); + + SendCommand("REIN"); + Console.WriteLine(ReceiveResponse()); +} + +void Help(){ + SendCommand("HELP"); + Console.WriteLine(ReceiveResponse()); +} + +void ChangeWorkingDirectory(string directory) +{ + path = directory; + + SendCommand("CWD " + directory); + Console.WriteLine(ReceiveResponse()); +} + +void ChangeDirectoryUP() +{ + path = path.Substring(0, path.LastIndexOf('/')); + + SendCommand("CDUP"); + Console.WriteLine(ReceiveResponse()); +} + +//No disponible en FreeFTPd +void StructureMount(string path) + { + SendCommand("SMNT " + path); + Console.WriteLine(ReceiveResponse()); + } + +void Port(string ipAddress, int _port) +{ + server = ipAddress; + port = _port; + + string[] ipParts = ipAddress.Split('.'); + int p1 = port / 256; + int p2 = port % 256; + + SendCommand($"PORT {ipParts[0]},{ipParts[1]},{ipParts[2]},{ipParts[3]},{p1},{p2}"); + Console.WriteLine(ReceiveResponse()); +} + +void SetTransferType(char type) + { + if(type != 'A' && type != 'I'){ + Console.WriteLine("Solo argumentos A, I"); + } + + SendCommand("TYPE " + type); + Console.WriteLine(ReceiveResponse()); + } + +//No disponible en FreeFTPd. Obsoleto en la mayoria de clientes y servidores FTP modernos +void SetFileStructure(char structure) + { + if(structure != 'F' && structure != 'R' && structure != 'P'){ + Console.WriteLine("Solo argumentos F, R, P"); + } + + SendCommand("STRU " + structure); + Console.WriteLine(ReceiveResponse()); + } + +//Solo disponible S en FreeFTPd +void SetTransferMode(char mode) + { + if(mode != 'S' && mode != 'C' && mode != 'B'){ + Console.WriteLine("Solo argumentos S, C, B"); + } + + SendCommand("MODE " + mode); + Console.WriteLine(ReceiveResponse()); + } + +void Nothing(){ + SendCommand("NOOP"); + Console.WriteLine(ReceiveResponse()); +} + +void Features(){ + SendCommand("FEAT"); + Console.WriteLine(ReceiveResponse()); +} + +void Close() +{ + SendCommand("QUIT"); + Console.WriteLine(ReceiveResponse()); + socket.Close(); +} + +//Por ahora solo funciona el pasivo +void UploadFile(string localFilePath, string remoteFileName) + { + if(active){ + SetActiveMode(); + + data_socket = dataSocketListener.Accept(); + Console.WriteLine("Mode setted up\n"); + + SendCommand("STOR " + remoteFileName); + string response = ReceiveResponse(); + Console.WriteLine(response); + + SendData(data_socket, localFilePath); // Enviar datos a traves del dataSocket + data_socket.Shutdown(SocketShutdown.Send); // Indica al servidor que no se enviarán más datos + data_socket.Close(); + + Console.WriteLine(ReceiveResponse()); //Recibe la respuesta final del servidor + + dataSocketListener.Close(); //Limpiar el listener para la proxima operacion, si es que la hay + } + else{ + SendCommand("STOR " + remoteFileName); + string response = ReceiveResponse(); + Console.WriteLine(response); + + data_socket.SendTimeout = 5000; + data_socket.ReceiveTimeout = 5000; + + try + { + SendData(data_socket, localFilePath); // Enviar datos a traves del dataSocket + } + catch (SocketException ex) + { + if (ex.SocketErrorCode == SocketError.TimedOut) AbortCommand(); + Console.WriteLine(ReceiveResponse()); //Recibe la respuesta final del servidor + } + finally + { + data_socket.Close(); + } + + // SetPassiveMode(); + + } + } + +void DownloadFile(string remoteFilePath, string localFilePath) +{ + SetPassiveMode(); + + SendCommand($"RETR {remoteFilePath}"); + Console.WriteLine(ReceiveResponse()); + + // 2. Recibir el archivo y guardarlo + FileStream fileStream = new FileStream(localFilePath, FileMode.Create, FileAccess.Write); + + byte[] buffer = new byte[4096]; + int bytesRead = int.MaxValue; + + data_socket.ReceiveTimeout = 10000; // 10 segundos de timeout + + Console.WriteLine("Conexión de datos establecida. Iniciando descarga..."); + while (bytesRead > 0) + { + try + { + bytesRead = data_socket.Receive(buffer, buffer.Length, SocketFlags.None); + fileStream.Write(buffer, 0, bytesRead); + } + catch (SocketException ex) + { + // Si ocurre una excepción de timeout, asumir que no hay más datos + if (ex.SocketErrorCode == SocketError.TimedOut) break; + } + } + Console.WriteLine($"Archivo descargado a {localFilePath}\n"); + + // 3. Cerrar la conexión de datos (importante) + fileStream.Close(); + data_socket.Shutdown(SocketShutdown.Both); + data_socket.Close(); + + // Console.WriteLine($"Transferencia completada: " + ReceiveResponse()); +} + +void AppendFile(string remoteFilePath, string localFilePath) +{ + SetPassiveMode(); + + SendCommand($"APPE {remoteFilePath}"); + Console.WriteLine(ReceiveResponse()); + + // 2. Recibir el archivo y guardarlo + FileStream fileStream = new FileStream(localFilePath, FileMode.Append, FileAccess.Write); + + byte[] buffer = new byte[4096]; + int bytesRead = int.MaxValue; + + data_socket.ReceiveTimeout = 10000; // 10 segundos de timeout + + while (bytesRead > 0) + { + try + { + bytesRead = data_socket.Receive(buffer, buffer.Length, SocketFlags.None); + fileStream.Write(buffer, 0, bytesRead); + } + catch (SocketException ex) + { + // Si ocurre una excepción de timeout, asumir que no hay más datos + if (ex.SocketErrorCode == SocketError.TimedOut) break; + } + } + + // 3. Cerrar la conexión de datos (importante) + fileStream.Close(); + data_socket.Shutdown(SocketShutdown.Both); + data_socket.Close(); + + // Console.WriteLine($"Transferencia completada: " + ReceiveResponse()); +} + +void RenameFile(string oldName, string newName) +{ + // 1. Enviar el comando RNFR + SendCommand("RNFR " + oldName); + string rnfrResponse = ReceiveResponse(); + Console.WriteLine(rnfrResponse); + + // 2. Verificar la respuesta (esperar "350 File exists, ready for destination name") + if (!rnfrResponse.StartsWith("350")) + { + Console.WriteLine("Error: El servidor no aceptó el comando RNFR."); + return; + } + + // 3. Enviar el comando RNTO + SendCommand("RNTO " + newName); + string rntoResponse = ReceiveResponse(); + Console.WriteLine(rntoResponse); + + // 4. Verificar la respuesta (esperar "250 Rename successful") + if (!rntoResponse.StartsWith("250")) + { + Console.WriteLine("Error: El servidor no aceptó el comando RNTO."); + return; + } + + Console.WriteLine("Archivo renombrado exitosamente."); +} + +void AbortCommand() + { + // 1. Enviar el comando ABOR + SendCommand("ABOR"); + Console.WriteLine(ReceiveResponse()); + + // 3. Cerrar la conexión de datos (si está abierta) + if (data_socket != null) + { + data_socket.Close(); + } + } + +void DeleteFile(string filePath, string fileName) +{ + string fullPath = $"{filePath.TrimStart('/')}/{fileName}"; + + try + { + SetPassiveMode(); + + // Eliminar archivo + SendCommand($"DELE {fullPath}"); + Console.WriteLine(ReceiveResponse()); + + data_socket.Close(); + } + catch (Exception ex) + { + Console.WriteLine("Error: " + ex.Message); + } +} + +void MakeDirectory(string directoryName) +{ + SendCommand("MKD " + directoryName); + string mkdResponse = ReceiveResponse(); + Console.WriteLine(mkdResponse); +} + +void RemoveDirectory(string directoryName) +{ + SendCommand("RMD " + directoryName); + string mkdResponse = ReceiveResponse(); + Console.WriteLine(mkdResponse); +} + +void PrintWorkingDirectory() + { + // 1. Enviar el comando PWD + SendCommand("PWD"); + string pwdResponse = ReceiveResponse(); + Console.WriteLine(pwdResponse); + + + // 3. Analizar la respuesta para extraer el directorio + string currentDirectory = null; + Regex regex = new Regex("\"(.*?)\""); + Match match = regex.Match(pwdResponse); + if (match.Success) + { + currentDirectory = match.Groups[1].Value; + } + + Console.WriteLine("Directorio de trabajo actual: " + currentDirectory); + } + +string ListFiles(string path = "") + { + SetPassiveMode(); + + SendCommand("LIST " + path); + string response = ReceiveResponse(); + Console.WriteLine(response); + + //Recibir datos a traves del dataSocket + string fileList = ReceiveData(data_socket); + data_socket.Close(); + + //Volver a establecer el modo pasivo para la proxima transferencia + SetPassiveMode(); + + return fileList; + } + + +Init(args[1], int.Parse(args[3]), args[5], args[7]); +Connect(user, password); + +if(args.Length >= 9){ + string command = args[9]; + string param_1 = string.Empty; + string param_2 = string.Empty; + + if(args.Length >= 11){ + param_1 = args[11]; + + // Descomentar para usar en Windows con Git bash + // param_1 = param_1.Substring(20, param_1.Length - 20); + } + if(args.Length >= 13){ + param_2 = args[13]; + + // Descomentar para usar en Windows con Git bash + // param_1 = param_1.Substring(20, param_1.Length - 20); + } + + switch (command) + { + case "NOOP": + { + Nothing(); + break; + } + case "PWD": + { + PrintWorkingDirectory(); + break; + } + case "CWD": + { + ChangeWorkingDirectory(param_1); + break; + } + case "CDUP": + { + ChangeDirectoryUP(); + break; + } + case "QUIT": + { + Close(); + break; + } + case "RETR": + { + SetPassiveMode(); + DownloadFile(param_1, "."); + break; + } + case "STOR": + { + SetPassiveMode(); + UploadFile(param_1, param_2); + break; + } + case "ABOR": + { + SetPassiveMode(); + AbortCommand(); + break; + } + case "RNFR": + { + RenameFile(param_1, param_2); + break; + } + case "DELE": + { + DeleteFile(path, param_1); + break; + } + case "MKD": + { + MakeDirectory(param_1); + break; + } + case "RMD": + { + RemoveDirectory(param_1); + break; + } + default: + break; + } +} +// Console.ReadLine(); \ No newline at end of file diff --git a/client/Redes socket version.csproj b/client/Redes socket version.csproj new file mode 100644 index 00000000..82446804 --- /dev/null +++ b/client/Redes socket version.csproj @@ -0,0 +1,11 @@ + + + + Exe + net8.0 + Redes_socket_version + enable + enable + + + diff --git a/client/bin/Debug/net8.0/Redes socket version.deps.json b/client/bin/Debug/net8.0/Redes socket version.deps.json new file mode 100644 index 00000000..16e8825f --- /dev/null +++ b/client/bin/Debug/net8.0/Redes socket version.deps.json @@ -0,0 +1,23 @@ +{ + "runtimeTarget": { + "name": ".NETCoreApp,Version=v8.0", + "signature": "" + }, + "compilationOptions": {}, + "targets": { + ".NETCoreApp,Version=v8.0": { + "Redes socket version/1.0.0": { + "runtime": { + "Redes socket version.dll": {} + } + } + } + }, + "libraries": { + "Redes socket version/1.0.0": { + "type": "project", + "serviceable": false, + "sha512": "" + } + } +} \ No newline at end of file diff --git a/client/bin/Debug/net8.0/Redes socket version.dll b/client/bin/Debug/net8.0/Redes socket version.dll new file mode 100644 index 00000000..47a8531e Binary files /dev/null and b/client/bin/Debug/net8.0/Redes socket version.dll differ diff --git a/client/bin/Debug/net8.0/Redes socket version.exe b/client/bin/Debug/net8.0/Redes socket version.exe new file mode 100644 index 00000000..6a19cac4 Binary files /dev/null and b/client/bin/Debug/net8.0/Redes socket version.exe differ diff --git a/client/bin/Debug/net8.0/Redes socket version.pdb b/client/bin/Debug/net8.0/Redes socket version.pdb new file mode 100644 index 00000000..83ce5ed5 Binary files /dev/null and b/client/bin/Debug/net8.0/Redes socket version.pdb differ diff --git a/client/bin/Debug/net8.0/Redes socket version.runtimeconfig.json b/client/bin/Debug/net8.0/Redes socket version.runtimeconfig.json new file mode 100644 index 00000000..1de3a5db --- /dev/null +++ b/client/bin/Debug/net8.0/Redes socket version.runtimeconfig.json @@ -0,0 +1,12 @@ +{ + "runtimeOptions": { + "tfm": "net8.0", + "framework": { + "name": "Microsoft.NETCore.App", + "version": "8.0.0" + }, + "configProperties": { + "System.Runtime.Serialization.EnableUnsafeBinaryFormatterSerialization": false + } + } +} \ No newline at end of file diff --git a/client/obj/Debug/net8.0/Redes socket version.AssemblyInfo.cs b/client/obj/Debug/net8.0/Redes socket version.AssemblyInfo.cs new file mode 100644 index 00000000..6b126b58 --- /dev/null +++ b/client/obj/Debug/net8.0/Redes socket version.AssemblyInfo.cs @@ -0,0 +1,22 @@ +//------------------------------------------------------------------------------ +// +// This code was generated by a tool. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +// +//------------------------------------------------------------------------------ + +using System; +using System.Reflection; + +[assembly: System.Reflection.AssemblyCompanyAttribute("Redes socket version")] +[assembly: System.Reflection.AssemblyConfigurationAttribute("Debug")] +[assembly: System.Reflection.AssemblyFileVersionAttribute("1.0.0.0")] +[assembly: System.Reflection.AssemblyInformationalVersionAttribute("1.0.0")] +[assembly: System.Reflection.AssemblyProductAttribute("Redes socket version")] +[assembly: System.Reflection.AssemblyTitleAttribute("Redes socket version")] +[assembly: System.Reflection.AssemblyVersionAttribute("1.0.0.0")] + +// Generated by the MSBuild WriteCodeFragment class. + diff --git a/client/obj/Debug/net8.0/Redes socket version.AssemblyInfoInputs.cache b/client/obj/Debug/net8.0/Redes socket version.AssemblyInfoInputs.cache new file mode 100644 index 00000000..c429ddf9 --- /dev/null +++ b/client/obj/Debug/net8.0/Redes socket version.AssemblyInfoInputs.cache @@ -0,0 +1 @@ +fef6bb71f432102af3e2fe260947df9c641672f508b10791d1e4e231762ce2d4 diff --git a/client/obj/Debug/net8.0/Redes socket version.GeneratedMSBuildEditorConfig.editorconfig b/client/obj/Debug/net8.0/Redes socket version.GeneratedMSBuildEditorConfig.editorconfig new file mode 100644 index 00000000..5762b1e5 --- /dev/null +++ b/client/obj/Debug/net8.0/Redes socket version.GeneratedMSBuildEditorConfig.editorconfig @@ -0,0 +1,13 @@ +is_global = true +build_property.TargetFramework = net8.0 +build_property.TargetPlatformMinVersion = +build_property.UsingMicrosoftNETSdkWeb = +build_property.ProjectTypeGuids = +build_property.InvariantGlobalization = +build_property.PlatformNeutralAssembly = +build_property.EnforceExtendedAnalyzerRules = +build_property._SupportedPlatformList = Linux,macOS,Windows +build_property.RootNamespace = Redes_socket_version +build_property.ProjectDir = c:\Users\Raidel Miguel\Desktop\computer_networks_project-main\client\ +build_property.EnableComHosting = +build_property.EnableGeneratedComInterfaceComImportInterop = diff --git a/client/obj/Debug/net8.0/Redes socket version.GlobalUsings.g.cs b/client/obj/Debug/net8.0/Redes socket version.GlobalUsings.g.cs new file mode 100644 index 00000000..ac22929d --- /dev/null +++ b/client/obj/Debug/net8.0/Redes socket version.GlobalUsings.g.cs @@ -0,0 +1,8 @@ +// +global using global::System; +global using global::System.Collections.Generic; +global using global::System.IO; +global using global::System.Linq; +global using global::System.Net.Http; +global using global::System.Threading; +global using global::System.Threading.Tasks; diff --git a/client/obj/Debug/net8.0/Redes socket version.assets.cache b/client/obj/Debug/net8.0/Redes socket version.assets.cache new file mode 100644 index 00000000..7e831570 Binary files /dev/null and b/client/obj/Debug/net8.0/Redes socket version.assets.cache differ diff --git a/client/obj/Debug/net8.0/Redes socket version.csproj.CoreCompileInputs.cache b/client/obj/Debug/net8.0/Redes socket version.csproj.CoreCompileInputs.cache new file mode 100644 index 00000000..ad80f9cd --- /dev/null +++ b/client/obj/Debug/net8.0/Redes socket version.csproj.CoreCompileInputs.cache @@ -0,0 +1 @@ +e1c2aec6e405b26ee5933ad27098631312fcac784d1a432b429ba8eef1f4dd8e diff --git a/client/obj/Debug/net8.0/Redes socket version.csproj.FileListAbsolute.txt b/client/obj/Debug/net8.0/Redes socket version.csproj.FileListAbsolute.txt new file mode 100644 index 00000000..af6eb1bb --- /dev/null +++ b/client/obj/Debug/net8.0/Redes socket version.csproj.FileListAbsolute.txt @@ -0,0 +1,42 @@ +C:\Users\Raidel Miguel\Desktop\Redes socket version\bin\Debug\net8.0\Redes socket version.exe +C:\Users\Raidel Miguel\Desktop\Redes socket version\bin\Debug\net8.0\Redes socket version.deps.json +C:\Users\Raidel Miguel\Desktop\Redes socket version\bin\Debug\net8.0\Redes socket version.runtimeconfig.json +C:\Users\Raidel Miguel\Desktop\Redes socket version\bin\Debug\net8.0\Redes socket version.dll +C:\Users\Raidel Miguel\Desktop\Redes socket version\bin\Debug\net8.0\Redes socket version.pdb +C:\Users\Raidel Miguel\Desktop\Redes socket version\obj\Debug\net8.0\Redes socket version.GeneratedMSBuildEditorConfig.editorconfig +C:\Users\Raidel Miguel\Desktop\Redes socket version\obj\Debug\net8.0\Redes socket version.AssemblyInfoInputs.cache +C:\Users\Raidel Miguel\Desktop\Redes socket version\obj\Debug\net8.0\Redes socket version.AssemblyInfo.cs +C:\Users\Raidel Miguel\Desktop\Redes socket version\obj\Debug\net8.0\Redes socket version.csproj.CoreCompileInputs.cache +C:\Users\Raidel Miguel\Desktop\Redes socket version\obj\Debug\net8.0\Redes socket version.dll +C:\Users\Raidel Miguel\Desktop\Redes socket version\obj\Debug\net8.0\refint\Redes socket version.dll +C:\Users\Raidel Miguel\Desktop\Redes socket version\obj\Debug\net8.0\Redes socket version.pdb +C:\Users\Raidel Miguel\Desktop\Redes socket version\obj\Debug\net8.0\Redes socket version.genruntimeconfig.cache +C:\Users\Raidel Miguel\Desktop\Redes socket version\obj\Debug\net8.0\ref\Redes socket version.dll +C:\Users\Raidel Miguel\Desktop\FTP client\bin\Debug\net8.0\Redes socket version.exe +C:\Users\Raidel Miguel\Desktop\FTP client\bin\Debug\net8.0\Redes socket version.deps.json +C:\Users\Raidel Miguel\Desktop\FTP client\bin\Debug\net8.0\Redes socket version.runtimeconfig.json +C:\Users\Raidel Miguel\Desktop\FTP client\bin\Debug\net8.0\Redes socket version.dll +C:\Users\Raidel Miguel\Desktop\FTP client\bin\Debug\net8.0\Redes socket version.pdb +C:\Users\Raidel Miguel\Desktop\FTP client\obj\Debug\net8.0\Redes socket version.GeneratedMSBuildEditorConfig.editorconfig +C:\Users\Raidel Miguel\Desktop\FTP client\obj\Debug\net8.0\Redes socket version.AssemblyInfoInputs.cache +C:\Users\Raidel Miguel\Desktop\FTP client\obj\Debug\net8.0\Redes socket version.AssemblyInfo.cs +C:\Users\Raidel Miguel\Desktop\FTP client\obj\Debug\net8.0\Redes socket version.csproj.CoreCompileInputs.cache +C:\Users\Raidel Miguel\Desktop\FTP client\obj\Debug\net8.0\Redes socket version.dll +C:\Users\Raidel Miguel\Desktop\FTP client\obj\Debug\net8.0\refint\Redes socket version.dll +C:\Users\Raidel Miguel\Desktop\FTP client\obj\Debug\net8.0\Redes socket version.pdb +C:\Users\Raidel Miguel\Desktop\FTP client\obj\Debug\net8.0\Redes socket version.genruntimeconfig.cache +C:\Users\Raidel Miguel\Desktop\FTP client\obj\Debug\net8.0\ref\Redes socket version.dll +C:\Users\Raidel Miguel\Desktop\computer_networks_project-main\client\bin\Debug\net8.0\Redes socket version.exe +C:\Users\Raidel Miguel\Desktop\computer_networks_project-main\client\bin\Debug\net8.0\Redes socket version.deps.json +C:\Users\Raidel Miguel\Desktop\computer_networks_project-main\client\bin\Debug\net8.0\Redes socket version.runtimeconfig.json +C:\Users\Raidel Miguel\Desktop\computer_networks_project-main\client\bin\Debug\net8.0\Redes socket version.dll +C:\Users\Raidel Miguel\Desktop\computer_networks_project-main\client\bin\Debug\net8.0\Redes socket version.pdb +C:\Users\Raidel Miguel\Desktop\computer_networks_project-main\client\obj\Debug\net8.0\Redes socket version.GeneratedMSBuildEditorConfig.editorconfig +C:\Users\Raidel Miguel\Desktop\computer_networks_project-main\client\obj\Debug\net8.0\Redes socket version.AssemblyInfoInputs.cache +C:\Users\Raidel Miguel\Desktop\computer_networks_project-main\client\obj\Debug\net8.0\Redes socket version.AssemblyInfo.cs +C:\Users\Raidel Miguel\Desktop\computer_networks_project-main\client\obj\Debug\net8.0\Redes socket version.csproj.CoreCompileInputs.cache +C:\Users\Raidel Miguel\Desktop\computer_networks_project-main\client\obj\Debug\net8.0\Redes socket version.dll +C:\Users\Raidel Miguel\Desktop\computer_networks_project-main\client\obj\Debug\net8.0\refint\Redes socket version.dll +C:\Users\Raidel Miguel\Desktop\computer_networks_project-main\client\obj\Debug\net8.0\Redes socket version.pdb +C:\Users\Raidel Miguel\Desktop\computer_networks_project-main\client\obj\Debug\net8.0\Redes socket version.genruntimeconfig.cache +C:\Users\Raidel Miguel\Desktop\computer_networks_project-main\client\obj\Debug\net8.0\ref\Redes socket version.dll diff --git a/client/obj/Debug/net8.0/Redes socket version.dll b/client/obj/Debug/net8.0/Redes socket version.dll new file mode 100644 index 00000000..47a8531e Binary files /dev/null and b/client/obj/Debug/net8.0/Redes socket version.dll differ diff --git a/client/obj/Debug/net8.0/Redes socket version.genruntimeconfig.cache b/client/obj/Debug/net8.0/Redes socket version.genruntimeconfig.cache new file mode 100644 index 00000000..c7b388f3 --- /dev/null +++ b/client/obj/Debug/net8.0/Redes socket version.genruntimeconfig.cache @@ -0,0 +1 @@ +31e875c584f7c79e063bdcb88ed6a8b9e68ddfafe9380ae6904ea11aca12307a diff --git a/client/obj/Debug/net8.0/Redes socket version.pdb b/client/obj/Debug/net8.0/Redes socket version.pdb new file mode 100644 index 00000000..83ce5ed5 Binary files /dev/null and b/client/obj/Debug/net8.0/Redes socket version.pdb differ diff --git a/client/obj/Debug/net8.0/apphost.exe b/client/obj/Debug/net8.0/apphost.exe new file mode 100644 index 00000000..6a19cac4 Binary files /dev/null and b/client/obj/Debug/net8.0/apphost.exe differ diff --git a/client/obj/Debug/net8.0/ref/Redes socket version.dll b/client/obj/Debug/net8.0/ref/Redes socket version.dll new file mode 100644 index 00000000..5063512b Binary files /dev/null and b/client/obj/Debug/net8.0/ref/Redes socket version.dll differ diff --git a/client/obj/Debug/net8.0/refint/Redes socket version.dll b/client/obj/Debug/net8.0/refint/Redes socket version.dll new file mode 100644 index 00000000..5063512b Binary files /dev/null and b/client/obj/Debug/net8.0/refint/Redes socket version.dll differ diff --git a/client/obj/Redes socket version.csproj.nuget.dgspec.json b/client/obj/Redes socket version.csproj.nuget.dgspec.json new file mode 100644 index 00000000..4d3f2c34 --- /dev/null +++ b/client/obj/Redes socket version.csproj.nuget.dgspec.json @@ -0,0 +1,61 @@ +{ + "format": 1, + "restore": { + "C:\\Users\\Raidel Miguel\\Desktop\\computer_networks_project-main\\client\\Redes socket version.csproj": {} + }, + "projects": { + "C:\\Users\\Raidel Miguel\\Desktop\\computer_networks_project-main\\client\\Redes socket version.csproj": { + "version": "1.0.0", + "restore": { + "projectUniqueName": "C:\\Users\\Raidel Miguel\\Desktop\\computer_networks_project-main\\client\\Redes socket version.csproj", + "projectName": "Redes socket version", + "projectPath": "C:\\Users\\Raidel Miguel\\Desktop\\computer_networks_project-main\\client\\Redes socket version.csproj", + "packagesPath": "C:\\Users\\Raidel Miguel\\.nuget\\packages\\", + "outputPath": "C:\\Users\\Raidel Miguel\\Desktop\\computer_networks_project-main\\client\\obj\\", + "projectStyle": "PackageReference", + "configFilePaths": [ + "C:\\Users\\Raidel Miguel\\AppData\\Roaming\\NuGet\\NuGet.Config" + ], + "originalTargetFrameworks": [ + "net8.0" + ], + "sources": { + "C:\\Users\\Raidel Miguel\\Documents\\Code\\dotnet-sdk-8.0.107-win-x64\\sdk\\8.0.107\\Sdks": {} + }, + "frameworks": { + "net8.0": { + "targetAlias": "net8.0", + "projectReferences": {} + } + }, + "warningProperties": { + "warnAsError": [ + "NU1605" + ] + } + }, + "frameworks": { + "net8.0": { + "targetAlias": "net8.0", + "imports": [ + "net461", + "net462", + "net47", + "net471", + "net472", + "net48", + "net481" + ], + "assetTargetFallback": true, + "warn": true, + "frameworkReferences": { + "Microsoft.NETCore.App": { + "privateAssets": "all" + } + }, + "runtimeIdentifierGraphPath": "C:\\Users\\Raidel Miguel\\Documents\\Code\\dotnet-sdk-8.0.107-win-x64\\sdk\\8.0.107/PortableRuntimeIdentifierGraph.json" + } + } + } + } +} \ No newline at end of file diff --git a/client/obj/Redes socket version.csproj.nuget.g.props b/client/obj/Redes socket version.csproj.nuget.g.props new file mode 100644 index 00000000..37f40dc6 --- /dev/null +++ b/client/obj/Redes socket version.csproj.nuget.g.props @@ -0,0 +1,15 @@ + + + + True + NuGet + $(MSBuildThisFileDirectory)project.assets.json + $(UserProfile)\.nuget\packages\ + C:\Users\Raidel Miguel\.nuget\packages\ + PackageReference + 6.8.1 + + + + + \ No newline at end of file diff --git a/client/obj/Redes socket version.csproj.nuget.g.targets b/client/obj/Redes socket version.csproj.nuget.g.targets new file mode 100644 index 00000000..35a7576c --- /dev/null +++ b/client/obj/Redes socket version.csproj.nuget.g.targets @@ -0,0 +1,2 @@ + + \ No newline at end of file diff --git a/client/obj/project.assets.json b/client/obj/project.assets.json new file mode 100644 index 00000000..345844ef --- /dev/null +++ b/client/obj/project.assets.json @@ -0,0 +1,66 @@ +{ + "version": 3, + "targets": { + "net8.0": {} + }, + "libraries": {}, + "projectFileDependencyGroups": { + "net8.0": [] + }, + "packageFolders": { + "C:\\Users\\Raidel Miguel\\.nuget\\packages\\": {} + }, + "project": { + "version": "1.0.0", + "restore": { + "projectUniqueName": "C:\\Users\\Raidel Miguel\\Desktop\\computer_networks_project-main\\client\\Redes socket version.csproj", + "projectName": "Redes socket version", + "projectPath": "C:\\Users\\Raidel Miguel\\Desktop\\computer_networks_project-main\\client\\Redes socket version.csproj", + "packagesPath": "C:\\Users\\Raidel Miguel\\.nuget\\packages\\", + "outputPath": "C:\\Users\\Raidel Miguel\\Desktop\\computer_networks_project-main\\client\\obj\\", + "projectStyle": "PackageReference", + "configFilePaths": [ + "C:\\Users\\Raidel Miguel\\AppData\\Roaming\\NuGet\\NuGet.Config" + ], + "originalTargetFrameworks": [ + "net8.0" + ], + "sources": { + "C:\\Users\\Raidel Miguel\\Documents\\Code\\dotnet-sdk-8.0.107-win-x64\\sdk\\8.0.107\\Sdks": {} + }, + "frameworks": { + "net8.0": { + "targetAlias": "net8.0", + "projectReferences": {} + } + }, + "warningProperties": { + "warnAsError": [ + "NU1605" + ] + } + }, + "frameworks": { + "net8.0": { + "targetAlias": "net8.0", + "imports": [ + "net461", + "net462", + "net47", + "net471", + "net472", + "net48", + "net481" + ], + "assetTargetFallback": true, + "warn": true, + "frameworkReferences": { + "Microsoft.NETCore.App": { + "privateAssets": "all" + } + }, + "runtimeIdentifierGraphPath": "C:\\Users\\Raidel Miguel\\Documents\\Code\\dotnet-sdk-8.0.107-win-x64\\sdk\\8.0.107/PortableRuntimeIdentifierGraph.json" + } + } + } +} \ No newline at end of file diff --git a/client/obj/project.nuget.cache b/client/obj/project.nuget.cache new file mode 100644 index 00000000..92a30ea2 --- /dev/null +++ b/client/obj/project.nuget.cache @@ -0,0 +1,8 @@ +{ + "version": 2, + "dgSpecHash": "lG5U5AFRaenwCV3IKZPpAJjOkaQ3VpY1van/NYDb58Z28PXzHcDoSaMJKQIkEkNpS3iADOvN3OOAP5DJFvhTsg==", + "success": true, + "projectFilePath": "C:\\Users\\Raidel Miguel\\Desktop\\computer_networks_project-main\\client\\Redes socket version.csproj", + "expectedPackageFiles": [], + "logs": [] +} \ No newline at end of file diff --git a/env.sh b/env.sh index b02d61a0..001beb50 100644 --- a/env.sh +++ b/env.sh @@ -7,7 +7,7 @@ # 3. SMTP # 4. IRC -PROTOCOL=1 +PROTOCOL=2 # Don't modify the next line echo "PROTOCOL=${PROTOCOL}" >> "$GITHUB_ENV" diff --git a/run.sh b/run.sh index a4751015..f93e40e4 100644 --- a/run.sh +++ b/run.sh @@ -2,4 +2,5 @@ # Replace the next shell command with the entrypoint of your solution -echo $@ \ No newline at end of file +cd client +dotnet run -- $@