Code · 15 lines · 382 bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15using MailSharp.SMTP.Extensions;
namespace MailSharp.SMTP.Session;

public partial class SmtpSession
{
	// Handle RSET command
	private async Task HandleRsetAsync(string[] parts, string line, CancellationToken ct)
	{
		state = SmtpState.HeloReceived;
		mailFrom = null;
		rcptTo.Clear();
		data.Clear();
		await writer.WriteLineAsync(configuration["SmtpResponses:Ok"], ct);
	}
}