Skip to content

Commit

Permalink
fix challenge timeout
Browse files Browse the repository at this point in the history
  • Loading branch information
mat-sz committed Nov 8, 2023
1 parent e4752c4 commit daade5a
Showing 1 changed file with 7 additions and 3 deletions.
10 changes: 7 additions & 3 deletions src/server/connection.ts
Original file line number Diff line number Diff line change
Expand Up @@ -293,9 +293,13 @@ export class SMTPServerConnection extends EventEmitter {
plaintextMessage = false,
plaintextReply = false
): Promise<string> {
this.reply(334, plaintextMessage ? message : base64Encode(message));
const reply = await this.wire.readLine();
return plaintextReply ? reply : base64Decode(reply);
try {
this.reply(334, plaintextMessage ? message : base64Encode(message));
const reply = await this.wire.readLine();
return plaintextReply ? reply : base64Decode(reply);
} catch {
return '';
}
}

private get authMethods() {
Expand Down

0 comments on commit daade5a

Please sign in to comment.