Why External Forwarding with Sendmail's virtusertable is A Bad Idea
If you run a mail server with sendmail, and a user wants to forward his mail to another server, one way is /etc/mail/virtusertable:
joe@example.com joe@gmail.com
As you probably know, the sender address of most spam mails belongs to someone - not the spammer of course. If you refuse to accept a spam email, you must never send back an error email to the alleged sender address. Otherwise, you have become a source of unsolicited email yourself.
When in our example, gmail.com does not accept an email, your server will send an error mail to the alleged sender address.
If you watch your postmaster mailbox, you will notice this every time the alleged sender address is invalid. You might be tempted to suppress these postmaster notifications with
define(`confDOUBLE_BOUNCE_ADDRESS', `')dnl
But this only supresses the double bounces. If the sender address is valid, someone will get an error email about spam he didn't send.
The solution is to not use virtusertable for external forwarding, but instead do it in /home/joe/.procmailrc:
:0 * ^From: Mail Delivery Subsystem <MAILER-DAEMON@example.com> * ^To: <joe@example.com> bounced-mails :0 ! joe@gmail.com
In this case, the sender address is set to joe@example.com before the mail is forwarded to gmail.com, and any error messages go back to joe.
21:28, 04 Jul 2008 by Carsten Clasohm Permalink | Comments (0)
Dell Latitude D800 Suspend to RAM with Fedora 7 [people.freedesktop.org]
Fedora 7 on a Dell D800 requires a little work to get suspend/resume working. The default configuration causes it to freeze during the resume, with the shift and scroll lock LEDs blinking.
The following has been tested with kernel-2.6.22.9-91.fc7 and NVIDIA-Linux-x86-100.14.19 on a Dell Latitude D800 with GeForce FX Go5200 graphics.
If you use the binary-only nvidia driver, append "agp=off" to the kernel line in /etc/grub.conf. This disables the built-in AGP driver and allows nvidia to load its own.
kernel /vmlinuz-2.6.22.9-91.fc7 ro root=/dev/vg1/root quiet agp=off
Edit /etc/X11/xorg.conf and set the NvAGP option:
Section "Device"
...
Driver "nvidia"
Option "NvAGP" "1"
EndSection
Reboot, log in and check if the nvidia AGP driver is used:
# cat /proc/driver/nvidia/agp/status Status: Enabled Driver: NVIDIA
Create /etc/pm/config.d/unload_modules with the following content:
SUSPEND_MODULES="uhci_hcd"
Create /etc/pm/config.d/nvidia with the following content:
DISPLAY_QUIRK_VBE_POST=false
Make the files executable with
chmod +x /etc/pm/config.d/unload_modules /etc/pm/config.d/nvidia
Suspend and resume should work now.
14:27, 15 Jun 2007 by Carsten Clasohm Permalink | Comments (0)
Vodafone UMTS with Fedora 7
After upgrading to Fedora 7, my Vodafone 3G Datacard (the old
UMTS PCMCIA adapter) stopped working. Here's what I had to do to
make it work again.
Create /etc/udev/rules.d/48-UMTS.rules with the following content:
BUS=="usb", KERNEL=="ttyUSB0", SYSFS{interface}=="Data Interface", SYMLINK+="umts", \
RUN+="/usr/bin/wvdial --config /etc/wvdial-pin.conf"
BUS=="usb", KERNEL=="ttyUSB2", SYSFS{interface}=="Data Interface", SYMLINK+="gsm"
The wvdial configuration for setting the PIN is stored in /etc/wvdial-pin.conf. Replace "1234" with your own PIN.
Modem = /dev/umts Baud = 460800 SetVolume = 0 Dial Command = ATDT FlowControl = NOFLOW Init1 = ATZ Init2 = AT+CPIN="1234"
/etc/wvdial.conf contains the settings for establishing an UMTS connection:
[ModemUMTS] Modem = /dev/umts Baud = 460800 SetVolume = 0 Dial Command = ATDT Init1 = ATZ Init2 = ATM0 Init3 = ATM0 FlowControl = NOFLOW [Dialer umts] Username = VFD2 Password = WAP Phone = *99***1# Stupid Mode = 1 Init1 = ATZ Init2 = ATQ0 V1 E1 S0=0 &C1 &D2 +FCLASS=0 Init3 = AT+CGDCONT=1,"IP","web.vodafone.de" Inherits = ModemUMTS
Next, we need to configure a network interface. Put this into /etc/sysconfig/network-scripts/ifcfg-umts:
IPV6INIT=no ONBOOT=no USERCTL=yes PEERDNS=yes TYPE=Modem DEVICE=ppp0 BOOTPROTO=dialup LINESPEED=460800 MODEMPORT=/dev/umts IDLETIMEOUT=300 PROVIDER=umts DEFROUTE=yes PERSIST=no WVDIALSECT=umts MODEMNAME=ModemUMTS DEMAND=no PAPNAME=VFD2 AC=off BSDCOMP=off VJCCOMP=off CCP=off PC=off VJ=off
This configuration has to be made available at two other locations:
ln /etc/sysconfig/network-scripts/ifcfg-umts \ /etc/sysconfig/networking/devices/ifcfg-umts ln /etc/sysconfig/network-scripts/ifcfg-umts \ /etc/sysconfig/networking/profiles/default/ifcfg-umts
Now, tell PPP about the connection in /etc/ppp/peers/umts:
connect "/usr/bin/wvdial --remotename umts --chat 'umts'"
In /etc/ppp/peers/chap-secrets and pap-secrets, append this line at the end:
"VFD2" * "WAP"
SELinux prevents udev from running wvdial, and initialization of the PIN fails. To get around this, create /tmp/udevwvdial.te:
module udevwvdial 1.0;
require {
type var_lock_t;
type udev_t;
class dir { write remove_name add_name };
class file { write read create unlink };
}
allow udev_t var_lock_t:dir { write remove_name add_name };
allow udev_t var_lock_t:file { write read create unlink };
Compile and load the SELinux module.
checkmodule -M -m -o udevwvdial.mod udevwvdial.te semodule_package -o udevwvdial.pp -m udevwvdial.mod semodule -i udevwvdial.pp
The semodule command stores the module in /etc/selinux, so it will stay active when you reboot.
You should now be able to establish a connection with ifup umts and terminate it with ifdown umts. When the card switches between UMTS and GPS, the connection attempt may time out, so retry before checking the configuration files.
18:23, 14 Jun 2007 by Carsten Clasohm Permalink | Comments (4)
| August 2008 | |||||||||||||||||||||||||||||||||||||||||||||||||
| |||||||||||||||||||||||||||||||||||||||||||||||||
Request notifications