Skip to content
Snippets Groups Projects
Commit 75f48421 authored by rswindell's avatar rswindell
Browse files

Removed RBL, RSS, and DUL checkboxes (replaced with dns_blacklist.cfg)

Added Blacklisted Mail radio buttons: Flag, Ignore, and Refuse.
Added Blacklisted Mail Flag edit box.
parent c5432af3
Branches
Tags
No related merge requests found
...@@ -105,6 +105,8 @@ void __fastcall TMailCfgDlg::FormShow(TObject *Sender) ...@@ -105,6 +105,8 @@ void __fastcall TMailCfgDlg::FormShow(TObject *Sender)
=AnsiString(MainForm->mail_startup.max_delivery_attempts); =AnsiString(MainForm->mail_startup.max_delivery_attempts);
RescanFreqEdit->Text=AnsiString(MainForm->mail_startup.rescan_frequency); RescanFreqEdit->Text=AnsiString(MainForm->mail_startup.rescan_frequency);
DefaultUserEdit->Text=AnsiString(MainForm->mail_startup.default_user); DefaultUserEdit->Text=AnsiString(MainForm->mail_startup.default_user);
BLMailFlagEdit->Text=AnsiString(MainForm->mail_startup.dnsbl_flag);
BLMailFlagEdit->Enabled=false;
DebugTXCheckBox->Checked=MainForm->mail_startup.options DebugTXCheckBox->Checked=MainForm->mail_startup.options
&MAIL_OPT_DEBUG_TX; &MAIL_OPT_DEBUG_TX;
...@@ -120,12 +122,14 @@ void __fastcall TMailCfgDlg::FormShow(TObject *Sender) ...@@ -120,12 +122,14 @@ void __fastcall TMailCfgDlg::FormShow(TObject *Sender)
&MAIL_OPT_ALLOW_RX_BY_NUMBER; &MAIL_OPT_ALLOW_RX_BY_NUMBER;
AllowRelayCheckBox->Checked=MainForm->mail_startup.options AllowRelayCheckBox->Checked=MainForm->mail_startup.options
&MAIL_OPT_ALLOW_RELAY; &MAIL_OPT_ALLOW_RELAY;
RBLCheckBox->Checked=MainForm->mail_startup.options if(MainForm->mail_startup.options&MAIL_OPT_DNSBL_REFUSE)
&MAIL_OPT_USE_RBL; BLMailRefuseRadioButton->Checked=true;
DULCheckBox->Checked=MainForm->mail_startup.options else if(MainForm->mail_startup.options&MAIL_OPT_DNSBL_IGNORE)
&MAIL_OPT_USE_DUL; BLMailIgnoreRadioButton->Checked=true;
RSSCheckBox->Checked=MainForm->mail_startup.options else {
&MAIL_OPT_USE_RSS; BLMailFlagRadioButton->Checked=true;
BLMailFlagEdit->Enabled=true;
}
TcpDnsCheckBox->Checked=MainForm->mail_startup.options TcpDnsCheckBox->Checked=MainForm->mail_startup.options
&MAIL_OPT_USE_TCP_DNS; &MAIL_OPT_USE_TCP_DNS;
SendMailCheckBox->Checked= SendMailCheckBox->Checked=
...@@ -182,6 +186,8 @@ void __fastcall TMailCfgDlg::OKBtnClick(TObject *Sender) ...@@ -182,6 +186,8 @@ void __fastcall TMailCfgDlg::OKBtnClick(TObject *Sender)
,OutboundSoundEdit->Text.c_str()); ,OutboundSoundEdit->Text.c_str());
SAFECOPY(MainForm->mail_startup.pop3_sound SAFECOPY(MainForm->mail_startup.pop3_sound
,POP3SoundEdit->Text.c_str()); ,POP3SoundEdit->Text.c_str());
SAFECOPY(MainForm->mail_startup.dnsbl_flag
,BLMailFlagEdit->Text.c_str());
if(RelayRadioButton->Checked==true) if(RelayRadioButton->Checked==true)
MainForm->mail_startup.options|=MAIL_OPT_RELAY_TX; MainForm->mail_startup.options|=MAIL_OPT_RELAY_TX;
...@@ -211,18 +217,12 @@ void __fastcall TMailCfgDlg::OKBtnClick(TObject *Sender) ...@@ -211,18 +217,12 @@ void __fastcall TMailCfgDlg::OKBtnClick(TObject *Sender)
MainForm->mail_startup.options|=MAIL_OPT_ALLOW_RELAY; MainForm->mail_startup.options|=MAIL_OPT_ALLOW_RELAY;
else else
MainForm->mail_startup.options&=~MAIL_OPT_ALLOW_RELAY; MainForm->mail_startup.options&=~MAIL_OPT_ALLOW_RELAY;
if(RBLCheckBox->Checked==true) MainForm->mail_startup.options&=
MainForm->mail_startup.options|=MAIL_OPT_USE_RBL; ~(MAIL_OPT_DNSBL_IGNORE|MAIL_OPT_DNSBL_REFUSE);
else if(BLMailIgnoreRadioButton->Checked==true)
MainForm->mail_startup.options&=~MAIL_OPT_USE_RBL; MainForm->mail_startup.options|=MAIL_OPT_DNSBL_IGNORE;
if(DULCheckBox->Checked==true) else if(BLMailRefuseRadioButton->Checked==true)
MainForm->mail_startup.options|=MAIL_OPT_USE_DUL; MainForm->mail_startup.options|=MAIL_OPT_DNSBL_REFUSE;
else
MainForm->mail_startup.options&=~MAIL_OPT_USE_DUL;
if(RSSCheckBox->Checked==true)
MainForm->mail_startup.options|=MAIL_OPT_USE_RSS;
else
MainForm->mail_startup.options&=~MAIL_OPT_USE_RSS;
if(HostnameCheckBox->Checked==false) if(HostnameCheckBox->Checked==false)
MainForm->mail_startup.options|=MAIL_OPT_NO_HOST_LOOKUP; MainForm->mail_startup.options|=MAIL_OPT_NO_HOST_LOOKUP;
else else
...@@ -300,3 +300,10 @@ void __fastcall TMailCfgDlg::SendMailCheckBoxClick(TObject *Sender) ...@@ -300,3 +300,10 @@ void __fastcall TMailCfgDlg::SendMailCheckBoxClick(TObject *Sender)
} }
//--------------------------------------------------------------------------- //---------------------------------------------------------------------------
void __fastcall TMailCfgDlg::BLMailFlagRadioButtonClick(TObject *Sender)
{
BLMailFlagEdit->Enabled=BLMailFlagRadioButton->Checked;
}
//---------------------------------------------------------------------------
...@@ -166,12 +166,13 @@ object MailCfgDlg: TMailCfgDlg ...@@ -166,12 +166,13 @@ object MailCfgDlg: TMailCfgDlg
object SMTPTabSheet: TTabSheet object SMTPTabSheet: TTabSheet
Caption = 'SMTP' Caption = 'SMTP'
ImageIndex = 1 ImageIndex = 1
object SpamFilterLabel: TLabel object BlacklistedMailLabel: TLabel
Left = 9 Left = 9
Top = 76 Top = 76
Width = 75 Width = 104
Height = 16 Height = 24
Caption = 'Spam Filters' AutoSize = False
Caption = 'Blacklisted Mail'
end end
object TelnetPortLabel: TLabel object TelnetPortLabel: TLabel
Left = 9 Left = 9
...@@ -189,39 +190,6 @@ object MailCfgDlg: TMailCfgDlg ...@@ -189,39 +190,6 @@ object MailCfgDlg: TMailCfgDlg
AutoSize = False AutoSize = False
Caption = 'Default User' Caption = 'Default User'
end end
object RBLCheckBox: TCheckBox
Left = 113
Top = 76
Width = 57
Height = 24
Hint = 'Use Realtime Blackhole List (RBL) Spam Filter'
Caption = 'RBL'
ParentShowHint = False
ShowHint = True
TabOrder = 3
end
object RSSCheckBox: TCheckBox
Left = 185
Top = 76
Width = 56
Height = 24
Hint = 'Use Relay Spam Stopper (RSS) Spam Filter'
Caption = 'RSS'
ParentShowHint = False
ShowHint = True
TabOrder = 4
end
object DULCheckBox: TCheckBox
Left = 256
Top = 76
Width = 57
Height = 24
Hint = 'Use Dail-up User List (DUL) Spam Filter'
Caption = 'DUL'
ParentShowHint = False
ShowHint = True
TabOrder = 5
end
object SMTPPortEdit: TEdit object SMTPPortEdit: TEdit
Left = 113 Left = 113
Top = 12 Top = 12
...@@ -233,14 +201,14 @@ object MailCfgDlg: TMailCfgDlg ...@@ -233,14 +201,14 @@ object MailCfgDlg: TMailCfgDlg
TabOrder = 0 TabOrder = 0
end end
object UserNumberCheckBox: TCheckBox object UserNumberCheckBox: TCheckBox
Left = 113 Left = 9
Top = 108 Top = 130
Width = 200 Width = 288
Height = 24 Height = 24
Hint = Hint =
'Allow mail to be received for users by number (i.e "1@yourbbs.co' + 'Allow mail to be received for users by number (e.g. "1@yourbbs.c' +
'm")' 'om")'
Caption = 'Allow RX by User Number' Caption = 'Allow Mail Addressed by User Number'
ParentShowHint = False ParentShowHint = False
ShowHint = True ShowHint = True
TabOrder = 1 TabOrder = 1
...@@ -254,7 +222,7 @@ object MailCfgDlg: TMailCfgDlg ...@@ -254,7 +222,7 @@ object MailCfgDlg: TMailCfgDlg
Caption = 'Log Headers' Caption = 'Log Headers'
ParentShowHint = False ParentShowHint = False
ShowHint = True ShowHint = True
TabOrder = 6 TabOrder = 3
end end
object DefaultUserEdit: TEdit object DefaultUserEdit: TEdit
Left = 113 Left = 113
...@@ -269,15 +237,61 @@ object MailCfgDlg: TMailCfgDlg ...@@ -269,15 +237,61 @@ object MailCfgDlg: TMailCfgDlg
TabOrder = 2 TabOrder = 2
end end
object AllowRelayCheckBox: TCheckBox object AllowRelayCheckBox: TCheckBox
Left = 113 Left = 9
Top = 140 Top = 162
Width = 198 Width = 288
Height = 24 Height = 24
Hint = 'Allow mail to be relayed for authenticated users' Hint = 'Allow mail to be relayed for authenticated users'
Caption = 'Allow Authenticated Relay' Caption = 'Allow Authenticated Users to Relay Mail'
ParentShowHint = False
ShowHint = True
TabOrder = 4
end
object BLMailFlagRadioButton: TRadioButton
Left = 112
Top = 76
Width = 57
Height = 24
Hint = 'Flag DNS-blacklisted mail with an X-RBL header'
Caption = 'Flag'
ParentShowHint = False
ShowHint = True
TabOrder = 5
OnClick = BLMailFlagRadioButtonClick
end
object BLMailIgnoreRadioButton: TRadioButton
Left = 176
Top = 76
Width = 57
Height = 24
Hint = 'Pretend to receive DNS-blacklisted mail '
Caption = 'Ignore'
ParentShowHint = False
ShowHint = True
TabOrder = 6
OnClick = BLMailFlagRadioButtonClick
end
object BLMailRefuseRadioButton: TRadioButton
Left = 248
Top = 76
Width = 73
Height = 24
Hint = 'Refuse mail session with DNS-blacklisted servers'
Caption = 'Refuse'
ParentShowHint = False ParentShowHint = False
ShowHint = True ShowHint = True
TabOrder = 7 TabOrder = 7
OnClick = BLMailFlagRadioButtonClick
end
object BLMailFlagEdit: TEdit
Left = 113
Top = 100
Width = 185
Height = 24
Hint = 'Flag to add to subject of DNS-blacklisted mail'
ParentShowHint = False
ShowHint = True
TabOrder = 8
end end
end end
object POP3TabSheet: TTabSheet object POP3TabSheet: TTabSheet
......
...@@ -67,10 +67,7 @@ __published: ...@@ -67,10 +67,7 @@ __published:
TLabel *MaxInactivityLabel; TLabel *MaxInactivityLabel;
TEdit *MaxInactivityEdit; TEdit *MaxInactivityEdit;
TTabSheet *SMTPTabSheet; TTabSheet *SMTPTabSheet;
TLabel *SpamFilterLabel; TLabel *BlacklistedMailLabel;
TCheckBox *RBLCheckBox;
TCheckBox *RSSCheckBox;
TCheckBox *DULCheckBox;
TLabel *TelnetPortLabel; TLabel *TelnetPortLabel;
TEdit *SMTPPortEdit; TEdit *SMTPPortEdit;
TCheckBox *UserNumberCheckBox; TCheckBox *UserNumberCheckBox;
...@@ -109,6 +106,10 @@ __published: ...@@ -109,6 +106,10 @@ __published:
TLabel *DefaultUserLabel; TLabel *DefaultUserLabel;
TEdit *DefaultUserEdit; TEdit *DefaultUserEdit;
TCheckBox *AllowRelayCheckBox; TCheckBox *AllowRelayCheckBox;
TRadioButton *BLMailFlagRadioButton;
TRadioButton *BLMailIgnoreRadioButton;
TRadioButton *BLMailRefuseRadioButton;
TEdit *BLMailFlagEdit;
void __fastcall InboundSoundButtonClick(TObject *Sender); void __fastcall InboundSoundButtonClick(TObject *Sender);
void __fastcall OutboundSoundButtonClick(TObject *Sender); void __fastcall OutboundSoundButtonClick(TObject *Sender);
void __fastcall FormShow(TObject *Sender); void __fastcall FormShow(TObject *Sender);
...@@ -117,6 +118,7 @@ __published: ...@@ -117,6 +118,7 @@ __published:
void __fastcall DNSRadioButtonClick(TObject *Sender); void __fastcall DNSRadioButtonClick(TObject *Sender);
void __fastcall POP3EnabledCheckBoxClick(TObject *Sender); void __fastcall POP3EnabledCheckBoxClick(TObject *Sender);
void __fastcall SendMailCheckBoxClick(TObject *Sender); void __fastcall SendMailCheckBoxClick(TObject *Sender);
void __fastcall BLMailFlagRadioButtonClick(TObject *Sender);
private: private:
public: public:
virtual __fastcall TMailCfgDlg(TComponent* AOwner); virtual __fastcall TMailCfgDlg(TComponent* AOwner);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment