E2e4.Chess.Fics.Client 1.0.0

Prefix Reserved
There is a newer version of this package available.
See the version list below for details.
dotnet add package E2e4.Chess.Fics.Client --version 1.0.0
                    
NuGet\Install-Package E2e4.Chess.Fics.Client -Version 1.0.0
                    
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="E2e4.Chess.Fics.Client" Version="1.0.0" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="E2e4.Chess.Fics.Client" Version="1.0.0" />
                    
Directory.Packages.props
<PackageReference Include="E2e4.Chess.Fics.Client" />
                    
Project file
For projects that support Central Package Management (CPM), copy this XML node into the solution Directory.Packages.props file to version the package.
paket add E2e4.Chess.Fics.Client --version 1.0.0
                    
#r "nuget: E2e4.Chess.Fics.Client, 1.0.0"
                    
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
#:package E2e4.Chess.Fics.Client@1.0.0
                    
#:package directive can be used in C# file-based apps starting in .NET 10 preview 4. Copy this into a .cs file before any lines of code to reference the package.
#addin nuget:?package=E2e4.Chess.Fics.Client&version=1.0.0
                    
Install as a Cake Addin
#tool nuget:?package=E2e4.Chess.Fics.Client&version=1.0.0
                    
Install as a Cake Tool

E2e4.Chess.Fics.Client

A cross-platform (net10.0) client library for the Free Internet Chess Server (FICS): System.IO.Pipelines framing, a typed message parser, style-12 board parsing, an IFicsTransport seam over TCP and an optional, pluggable timeseal codec. Install from NuGet: E2e4.Chess.Fics.Client.

This is an unofficial library. It is not affiliated with, or endorsed by, FICS or its administrators.

await using IFicsClient client = new FicsClientFactory(Options.Create(new FicsClientOptions()), new TcpFicsTransport()).Create();
client.BoardUpdated += (_, e) => Console.WriteLine(e.Board);
await client.ConnectAsync();
string user = await client.LoginAsGuestAsync();
await client.SendCommandAsync("seek 5 0");

With dependency injection, call services.AddFicsClient(options => ...) and inject IFicsClientFactory. A client is a single use session; long-lived services should inject the factory and dispose each client with DisposeAsync.

Licence

MIT, see LICENSE. The library has no dependency on any GPL code. Timeseal is optional and plugs in through ITimesealCodec (FicsClientOptions.Timeseal); leave it null to send plain lines. The test fixtures are synthetic; see NOTICE.

Using timeseal

The timeseal cipher is GPL v2 or later and lives in a separate package, E2e4.Chess.OpenSeal. An application that includes that package is distributed under the GPL. If you accept that, the adapter is one line:

sealed class OpenSealCodec : ITimesealCodec
{
    public string Encode(string line) => OpenSealCipher.Encode(line);
}

Do not reference E2e4.Chess.OpenSeal from a library you want to keep permissively licensed.

Privacy and security notes

  • FICS speaks plain, unencrypted Telnet. A password sent with LoginAsync and everything you chat crosses the network in the clear, and this library cannot change that. Prefer guest logins for demos, and never reuse a password from elsewhere.
  • Outbound lines are checked: a command, user name, password or interface name containing \r, \n or \0 is rejected, so a value cannot smuggle in a second command.
  • Inbound lines and frames have length caps, and the parser turns anything it does not understand into UnknownLineMessage instead of throwing.
  • The optional ILogger receives state changes and swallowed failures, never raw lines or passwords.
  • FicsClientOptions.Host defaults to freechess.org; point it elsewhere for another server.

Build and test

dotnet test E2e4.Chess.Fics.Client.slnx

See SECURITY.md to report a vulnerability.

Product Compatible and additional computed target framework versions.
.NET net10.0 is compatible.  net10.0-android was computed.  net10.0-browser was computed.  net10.0-ios was computed.  net10.0-maccatalyst was computed.  net10.0-macos was computed.  net10.0-tvos was computed.  net10.0-windows was computed. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

NuGet packages

This package is not used by any NuGet packages.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last Updated
1.2.0 50 11/19/2026
1.1.0 119 10/26/2026
1.0.0 120 10/15/2026

1.0.0: first release, split out of https://github.com/th3snark/E2e4.Chess. A FICS client for .NET 10: System.IO.Pipelines framing (with optional block mode), a typed message parser, style-12 board parsing, IFicsClient and IFicsClientFactory with dependency injection (AddFicsClient), a TCP transport behind an IFicsTransport seam, and an optional pluggable timeseal codec (ITimesealCodec; the package has no GPL dependency). Outbound lines containing CR, LF or NUL are rejected, inbound lines have length caps, and optional ILogger output never includes raw lines or passwords.