You probably want to start using the -w option with iptables
The other day, I got notified that my office workstation had anexposed portmapper service. That was frankly weird, because whileI had rpcbind running for some NFS experiments, I'd carefullyused iptables to block almost all access to it. Or at least Ithought I had; when I looked at ' iptables -vnL INPUT ', my blockson tcp:111 were conspicuously missing (although it did have theexplicit allow rules for the good traffic). So I went throughsystemd's logs
Git's selective commits plus Magit are a killer feature for me
I'm sure there are some people who are meticulously organized intheir programming work. They work on only one thing at a time, orif they're making multiple changes they carefully separate them ondifferent topic branches. I'm not one of them. I'm working away onsomething, but then I can't resist improving something that I stumbleover because I was in that area of the code, and I run into a bugthat needs to be corrected, and by the time I
Why we've wound up without ZFS ZILs or L2ARCs on our pools
Back when we designed the current generation of our ZFS fileservers , we expected to wind up putting in at leastsome ZILs (mirrored and in the backends) and L2ARCs (in the OmniOSfileservers). This has not wound up happening, as all of our plansfor this have basically fallen through. There are a number of reasonsfor this (independent of my thoughts on why an L2ARC probablyisn't a good fit for us , which sort ofcame later).
In one sense,
Today I learned that you want to use strace -fp
There I was, with an Ubuntu 16.04 system where rsyslogd seemed tohave stopped writing to an important syslog file for no clear reason.When in doubt (or in a hurry, or both), I reach for a big hammer:
# strace -p $(pidof rsyslogd)strace: Process 21950 attachedselect(1, NULL, NULL, NULL, {342, 910468}And there rsyslogd sat even while I sent in syslog
My view on spam and potential denial of service attacks on anti-spam systems
In a comment on yesterday's entry on a shift in malware packaging , Jinks asked a very good question:
Since you're working with inspecting zip files, how does your setuphandle denial of service attacks against the unzipping part?
Like, let's say I sent you a zipped 30TB sparse file. Or a neverendingzip quine.
I've found that many commercial solutions can easily choke onmaliciously crafted zip files. Do you have any special provisions inyour scripts to prevent these attacks?
A surprise with switching to holding keys in ssh-agent
Every so often I want to transfer a root-only file from my officeworkstation off to another machine for analysis or the like (thereasons this is necessary are complex). So every so often I windup doing this:
$ /bin/su# scp /some/file cks@server:/tmp/foobarcks@server's password: [...]
Except that I lied there. That password prompt is certainly whatused to happen and it's what happens when I do
A little shift in malware packaging that I got to watch
When we started rejecting email with certain sorts of malware init , almost all of the malware (reallyransomware) had a pretty consistent signature; it came as a ZIParchive (rarely a RAR archive) with a single bad file type in it.We could easily write a narrowly tailored rule that rejected anarchive with a single .js , .jse , .wsf , and so on file in it.Even when we didn't have such a rule ourselves, it seems that ourcommercial anti-spam
What encoding the syslog module uses in Python 3
Suppose that you're writing a Python 3 program that is going to syslog() some information through the syslog module . Given that one ofthe cardinal rules of Python 3 is that you should explicitly considerencoding issues any time you send data to the outside world andthat syslog() definitely does this, the immediate questions toask are how syslog handles encoding the Unicode string you'regiving it and if it can ever raise a Unicode encoding error.
(Anything that can raise a Unicode encoding error on output
A shell thing: globbing operators versus expansion operators
If you've been using a Unix shell for long, you may be familiar withthe ' [...] ' wildcard, which can be used to match a character range(or a bunch of characters):
ls -lt logfile.[1-5].gz
If you've used Bash or a number of other shells for a while, you mayalso be familiar with ' {..,...} ':
touch afile.{one,two,three}There
What I did to set up IPv6 on my wireless network
Last month I slapped together a home wireless network in a rush . Or more exactly I put together an IPv4wireless network; as I mentioned at the end, one of the things Ihad left to do was extend it to IPv6 as well. Today, for no goodreason, I decided that I was going to fix that and get at leastbasic IPv6 up and running. Even though I don't really know what I'mdoing here, I succeeded , at leastat the basics