pig-monkey.com - privacyhttps://pig-monkey.com/2022-02-24T20:58:12-08:00Better Payments with Privacy.com2022-02-24T00:00:00-08:002022-02-24T20:58:12-08:00Pig Monkeytag:pig-monkey.com,2022-02-24:/2022/02/better-payments-privacy/<p><a href="https://privacy.com">Privacy.com</a> is an excellent service with a terrible name. They provide merchant-locked virtual debit cards. I&rsquo;ve been using them for about three years. Around 90% of my online transactions go through them (the other 10%-ish is PayPal).</p> <p>When one of their card numbers is first used, it …</p><p><a href="https://privacy.com">Privacy.com</a> is an excellent service with a terrible name. They provide merchant-locked virtual debit cards. I&rsquo;ve been using them for about three years. Around 90% of my online transactions go through them (the other 10%-ish is PayPal).</p> <p>When one of their card numbers is first used, it becomes locked to that merchant. The card will reject transactions from anyone else. This immediately eliminates the problem of stolen card numbers. If a random ecommerce website leaks my card details, I don&rsquo;t care, because nobody other than the original merchant can place a charge on the card.</p> <p>When generating cards, Privacy.com also allows you to set dollar limits, either in total or for a period of time. This eliminates the problem of unreliable subscription services. For example, the card tied to my Amazon Web Services account has a monthly usage limit slightly higher than my average monthly bill. If AWS tries to double my bill one month, the transaction will be rejected.</p> <p>Cards can also be paused. While I use the periodic dollar limit feature for things like subscription services with regular payments, other cards in my Privacy.com account stay paused when not in use. A paused card rejects all new transactions. Before making a purchase on a website, I login to the Privacy.com website and unpause the associated card. I then make the purchase as usual. Placing an order usually results in the merchant immediately placing an authorization on the card for the purchase amount. Existing authorizations can still be captured on a paused card, so at this point I can switch back to my Privacy.com tab and re-pause the card, preventing the merchant from taking any more money than the agreed upon authorization.</p> <p>Cards can also be closed. Effectively this is the same as pausing a card, except that it is permanent. This is useful for signing up for free trials that still require a method of payment. When the trial is up, if you choose to not continue using the service, inform the provider and simply close the card.</p> <p>Privacy.com offers <a href="https://play.google.com/store/apps/details?id=com.privacy.pay">software you can install on your telephone</a>. I&rsquo;ve never used it. I don&rsquo;t trust my phone enough for it to touch money in any way. They also offer <a href="https://addons.mozilla.org/en-US/firefox/addon/pay-by-privacy-com/">browser extensions</a>, which I also have never used. Their website works great, and I see no need for locally installed software of any sort.</p> <p>Over my few years of using Privacy.com, I&rsquo;ve never had a problem with their service. I&rsquo;ve never had to contact their customer support, so I have no idea how that works. I&rsquo;ve had merchants issue refunds to my Privacy.com cards half a dozen or so times, and those have always come through and landed in my bank account without drama (even when the original charge was on a card that at the time of refund was paused or closed.</p> <p>Last year, <a href="https://swiftsilentdeadly.com/eliminate-online-credit-card-theft-privacy-com/">Swift Silent Deadly posted an in-depth overview of Privacy.com</a>. This provides a good overview of the service. What he wrote matches my experience, with one glaring exception. He mentions giving Privacy.com access to your bank account. I don&rsquo;t know if he is referencing some <a href="https://drewdevault.com/2022/02/19/Plaid-is-an-evil-nightmare-product.html">shady Plaid bullshit</a> or if he simply means providing them with routing and account numbers and going through ACH. I did neither. When I signed up, Privacy.com allowed me to add my real bank debit card as a funding source. That is the only way Privacy.com has to push or pull funds from me. If they ever become untrustworthy, I can just cancel my real debit card, and Privacy.com will loose all access to my money.</p> <p>The debit card that I use for this is tied to <a href="/2015/12/proxy/">the checking account that I previously used only for PayPal</a>. This provides an additional layer of defense, in that there isn&rsquo;t much money hanging around in that account for someone to steal. I usually keep around $100 in it for incidental purchases, and transfer more in from my real accounts when I plan to make a larger purchase.</p> <p>Privacy.com has free and <a href="https://privacy.com/pricing">paid tiers</a>. I am on the free tier. Apparently it has some limitations in terms of number of cards generated per month and total monthly spend. I have never run into these limitations so I have no idea what they are. They claim that they make enough money on us low-volume free tier users by collecting the transaction fees that merchants pay to process debit cards. I would be very unhappy to return to participating in the electronic commerce market without a service like this, so they would probably have a pretty easy time convincing me to move to a paid plan if they ever decided to eliminate the free tier.</p> <p>I&rsquo;ve heard some banks offer virtual card numbers somewhat similar to Privacy.com, but perhaps without the merchant-locking and spend limits. While I refer to my &ldquo;bank&rdquo; accounts, my accounts are actually with credit unions. Credit unions tend not to be at the forefront of technology, so I need a third-party to provide this functionality.</p> <p>Privacy.com says that they offer merchant masking to their paying customers. This means that transactions show up in your bank account as &ldquo;Privacy.com&rdquo; instead of including the name of the merchant. I suspect this may be where their business name comes from. I suppose that is great if you have a joint bank account and want to hide your Porn Hub subscription from your spouse. But it is not a problem I have, so I maintain that their name is dumb and has nothing to do with their excellent service. If anything they reduce my privacy, since they are now an additional party involved in all of my online purchases. But I&rsquo;m good with that trade-off.</p>Identifying individuals by using a laser to record the vibrations of their heartbeat is a neat idea.2019-06-27T00:00:00-07:002019-06-27T19:53:31-07:00Pig Monkeytag:pig-monkey.com,2019-06-27:/2019/06/cardiac-signature/<p>The <a href="https://www.technologyreview.com/s/613891/the-pentagon-has-a-laser-that-can-identify-people-from-a-distanceby-their-heartbeat/">Pentagon&rsquo;s new Jetson laser</a> sounds like a simple concept:</p> <blockquote> <p>A new device, developed for the Pentagon after US Special Forces requested it, can identify people without seeing their face: instead it detects their unique cardiac signature with an infrared laser. While it works at 200 meters (219 yards …</p></blockquote><p>The <a href="https://www.technologyreview.com/s/613891/the-pentagon-has-a-laser-that-can-identify-people-from-a-distanceby-their-heartbeat/">Pentagon&rsquo;s new Jetson laser</a> sounds like a simple concept:</p> <blockquote> <p>A new device, developed for the Pentagon after US Special Forces requested it, can identify people without seeing their face: instead it detects their unique cardiac signature with an infrared laser. While it works at 200 meters (219 yards), longer distances could be possible with a better laser. “I don’t want to say you could do it from space,” says Steward Remaly, of the Pentagon’s Combatting Terrorism Technical Support Office, “but longer ranges should be possible.”</p> <p>Contact infrared sensors are often used to automatically record a patient’s pulse. They work by detecting the changes in reflection of infrared light caused by blood flow. By contrast, the new device, called Jetson, uses a technique known as laser vibrometry to detect the surface movement caused by the heartbeat. This works though typical clothing like a shirt and a jacket (though not thicker clothing such as a winter coat).</p> </blockquote> <p>I wonder if they aim center mass, or if they can get a reading off the carotid. If it&rsquo;s the former, it seems likely to be defeated by wearing plates, which is probably good life advice if the Pentagon is interested in you anyways.</p> <p>The article also mentions that &ldquo;[o]ne glaring limitation is the need for a database of cardiac signatures&rdquo;, but I suspect they can just acquire that data from Apple, Strava, Fitbit, etc.</p> <p><a href="https://attrition.org/mailman/listinfo/infowarrior">via Infowarrior</a></p>Geoff Manaugh discusses the deception and misdirection of robot vision.2016-07-23T00:00:00-07:002016-07-22T19:27:23-07:00Pig Monkeytag:pig-monkey.com,2016-07-23:/2016/07/elision/<p>Starting with the <a href="https://www.tesla.com/blog/tragic-loss">recent Tesla crash</a> caused by the car&rsquo;s inability to discern the tractor against the bright sky, <a href="http://www.bldgblog.com/2016/07/robot-war-and-the-future-of-perceptual-deception/">Geoff discusses how the spread of robots may force us to rebuild our environment</a> &ndash; either to support their perceptual systems or hinder them. It&rsquo;s an interesting idea to ponder …</p><p>Starting with the <a href="https://www.tesla.com/blog/tragic-loss">recent Tesla crash</a> caused by the car&rsquo;s inability to discern the tractor against the bright sky, <a href="http://www.bldgblog.com/2016/07/robot-war-and-the-future-of-perceptual-deception/">Geoff discusses how the spread of robots may force us to rebuild our environment</a> &ndash; either to support their perceptual systems or hinder them. It&rsquo;s an interesting idea to ponder, particularly within the context of <a href="http://qz.com/185945/drones-are-about-to-upheave-society-in-a-way-we-havent-seen-in-700-years/">the rise of drones</a>. Readers of <a href="https://en.wikipedia.org/wiki/Daemon_(technothriller_series)">Daniel Suarez</a> can sleep easier at night knowing that razorbacks can probably be defeated with a few mirrors and rubber.</p> <blockquote> <p>One possible line of defense—among many, of course—would be to redesign your city, even down to the interior of your own home, such that machine vision is constantly confused there. You thus rebuild the world using light-absorbing fabrics and reflective ornament, installing projections and mirrors, screens and smoke. Or “stealth objects” and radar-baffling architectural geometries. A military robot wheeling its way into your home thus simply gets lost there, stuck in a labyrinth of perceptual convolution and reflection-implied rooms that don’t exist.</p> </blockquote>Cryptographic Identity2016-05-17T00:00:00-07:002016-05-17T20:56:35-07:00Pig Monkeytag:pig-monkey.com,2016-05-17:/2016/05/id/<p>Despite its shortcomings, I think PGP is still one of the better ways to verify a person&rsquo;s identity. Because of this &ndash; and because I use my PGP key daily<sup class="footnote-ref" id="fnref:key-use"><a rel="footnote" href="#fn:key-use" title="see footnote">1</a></sup> &ndash; I make an effort to properly secure my private key. Verifying a PGP key is a fairly straightforward process …</p><p>Despite its shortcomings, I think PGP is still one of the better ways to verify a person&rsquo;s identity. Because of this &ndash; and because I use my PGP key daily<sup class="footnote-ref" id="fnref:key-use"><a rel="footnote" href="#fn:key-use" title="see footnote">1</a></sup> &ndash; I make an effort to properly secure my private key. Verifying a PGP key is a fairly straightforward process for fellow PGP users, and my hope is that anyone who does verify my key can maintain a high confidence in its signature.</p> <p>However, I also use other cryptographic channels to communicate &ndash; XMPP/OTR and Signal chief among them. I consider these keys more transient than PGP. The OTR keys on my computer are backed up because it takes no effort to do so, but I have no qualms about creating new ones if I feel like it. I don&rsquo;t bother to port the same keys to other devices, like my phone. My Signal key is guaranteed to change anytime I rebuild or replace my phone. Given the nature of these keys and how I handle them, I don&rsquo;t expect others to put the same amount of effort into verifying their fingerprints.</p> <p>The solution to this is to maintain a simple text file, signed via PGP, containing the fingerprints of my other keys. With a copy of the file and a trusted copy of my public PGP key, anyone can verify my identity on other networks or communication channels. If a key is replaced, I simply add the new fingerprint to the file, sign it and distribute. Contacts download the file, check its signature, and thus easily trust the new fingerprint without additional rigmarole.</p> <p>The first examples of this that I saw were from <a href="http://web.mit.edu/zyan/www/zyan.txt">Yan</a> and <a href="https://tomlowenthal.com/id">Tom Lowenthal</a>. I thought it seemed like a great idea and began to maintain a file with a list of examples whenever I stumbled across then, with a note that I should do that someday<sup class="footnote-ref" id="fnref:keybase"><a rel="footnote" href="#fn:keybase" title="see footnote">2</a></sup>.</p> <p>Today I decided to stop procrastinating on this and create my own identity file. It is located at <a href="/id.txt">pig-monkey.com/id.txt</a>. The file, along with the rest of this website, is <a href="https://github.com/pigmonkey/pig-monkey.com/blob/master/content/id.txt">in git</a> so that changes to it may be tracked over time.</p> <p>Inspired by some of the examples I had collected, I added a couple pieces of related information to the file. The section on PGP key signing should provide others some context for what it means when they see my signature on a different key. Even if no one cares, I found it useful to enunciate the policy simply to clear up my own thinking about what the different certification levels should mean. Finally, the section on key management gives others a rough idea about how I manage my key, which should help them to maintain their confidence in it. If I verify that someone&rsquo;s identity and fingerprint match their key, I will have high confidence in its signature initially. But if I know that the person keeps their secret key on their daily driver machine without any additional effort to protect it, my confidence in it will degrade over time. Less so if I know that they take great care and handling in their key&rsquo;s protection.</p> <p>A file like this should also provide a good mechanism for creating a transition and revocation statement for my PGP key, should the need arise. One hopes that it does not.</p> <div id="footnotes"> <h2>Notes</h2> <ol> <li id="fn:key-use"><a rev="footnote" href="#fnref:key-use" class="footnote-return" title="return to article">&crarr;</a> Realistically, I use PGP multiple times per hour when I'm on my computer.</li> <li id="fn:keybase"><a rev="footnote" href="#fnref:keybase" class="footnote-return" title="return to article">&crarr;</a> Since I began my list, <a href="https://keybase.io/">Keybase</a> has become a thing. It addresses a similar problem, although seems to promote using services like Twitter as the root of trust. Assuming that you want to stubbornly stick with a PGP key as the root of trust, I don't see the advantage of using Keybase for this problem, except that it offers a centralized lookup repository.</li> </ol> </div>Lately I've had trouble finding prepaid debit cards in denominations greater than $50.2016-04-19T00:00:00-07:002016-04-19T21:54:38-07:00Pig Monkeytag:pig-monkey.com,2016-04-19:/2016/04/cash/<p>It&rsquo;s 2016, and stuffing cash in an envelope and mailing it to a small island nation is sometimes still the best way to move money with some degree of privacy.</p> <p>This is not the cyberpunk dystopia I was promised.</p>Isolating Chrome Apps with Firejail2016-03-29T00:00:00-07:002016-03-29T19:14:51-07:00Pig Monkeytag:pig-monkey.com,2016-03-29:/2016/03/isolation/<p>Despite its terse man page, Chromium provides <a href="http://peter.sh/experiments/chromium-command-line-switches/">a large number of command-line options</a>. One of these is <code>app-id</code>, which tells Chromium to directly launch a specific <a href="https://chrome.google.com/webstore/category/apps">Chrome App</a>. Combined with the isolation provided by <a href="https://firejail.wordpress.com/">Firejail</a>, this makes using Chrome Apps a much more enjoyable experience.</p> <p>For instance, I use the …</p><p>Despite its terse man page, Chromium provides <a href="http://peter.sh/experiments/chromium-command-line-switches/">a large number of command-line options</a>. One of these is <code>app-id</code>, which tells Chromium to directly launch a specific <a href="https://chrome.google.com/webstore/category/apps">Chrome App</a>. Combined with the isolation provided by <a href="https://firejail.wordpress.com/">Firejail</a>, this makes using Chrome Apps a much more enjoyable experience.</p> <p>For instance, I use the <a href="https://whispersystems.org/blog/signal-desktop/">Signal Desktop app</a>. When I received the beta invite, I created a new directory to act as the home directory for the sandbox that would run the app.</p> <div class="highlight"><pre><span></span><code>$ mkdir -p ~/.chromium-apps/signal </code></pre></div> <p>I then launched a sandboxed browser using that directory and installed the app.</p> <div class="highlight"><pre><span></span><code>$ firejail --private<span class="o">=</span>~/.chromium-apps/signal /usr/bin/chromium </code></pre></div> <p>After the app was installed, I added an alias to my zsh configuration to launch the app directly.</p> <div class="highlight"><pre><span></span><code><span class="n">alias</span><span class="w"> </span><span class="k">signal</span><span class="o">=</span><span class="s2">&quot;firejail --private=~/.chromium-apps/signal /usr/bin/chromium --app-id=bikioccmkafdpakkkcpdbppfkghcmihk&quot;</span><span class="w"></span> </code></pre></div> <p>To launch the application I can now simply run <code>signal</code>, just as if it was a normal desktop application. I don&rsquo;t have to worry about it accessing private information, or even care that it is actually running on Chromium underneath. I use this method daily for a number of different Chrome Apps, all in different isolated directories in <code>~/.chromium-apps</code>. As someone who is not a normal Chromium user, it makes the prospect of running a Chrome App much more attractive.</p>I stopped worrying and embraced the security freeze.2016-02-28T00:00:00-08:002016-02-28T16:18:09-08:00Pig Monkeytag:pig-monkey.com,2016-02-28:/2016/02/freeze/<p>A credit security freeze denies access to your credit file. I first learned about it last summer from <a href="http://krebsonsecurity.com/2015/06/how-i-learned-to-stop-worrying-and-embrace-the-security-freeze/">Brian Krebs</a>, but didn&rsquo;t implement it until a couple months later. It took me about 45 minutes and $20 to activate the freeze with the five major credit bureaus. This goes …</p><p>A credit security freeze denies access to your credit file. I first learned about it last summer from <a href="http://krebsonsecurity.com/2015/06/how-i-learned-to-stop-worrying-and-embrace-the-security-freeze/">Brian Krebs</a>, but didn&rsquo;t implement it until a couple months later. It took me about 45 minutes and $20 to activate the freeze with the five major credit bureaus. This goes a long way to reducing the threat of identify theft, with very little energy expenditure required. A proactive defense is superior to reactive monitoring services. If you need your credit pulled monthly or more frequently, constantly freezing and unfreezing your file would probably be an annoying inconvenience. For the rest of us, I&rsquo;m not sure if there is any good reason not to enable the freeze.</p>Firewarden2016-02-05T00:00:00-08:002019-01-04T16:58:19-08:00Pig Monkeytag:pig-monkey.com,2016-02-05:/2016/02/firewarden/<p>I&rsquo;ve <a href="/2015/08/firejail/">previously mentioned</a> the <a href="https://firejail.wordpress.com/">Firejail</a> sandbox program. It&rsquo;s an incredibly useful tool. I use it to jail pretty much <a href="https://github.com/pigmonkey/spark/search?q=firejail">all the things</a>. Over the past six months, I&rsquo;ve found that one of my primary use cases for Firejail is to create private, temporary sandboxes which can be …</p><p>I&rsquo;ve <a href="/2015/08/firejail/">previously mentioned</a> the <a href="https://firejail.wordpress.com/">Firejail</a> sandbox program. It&rsquo;s an incredibly useful tool. I use it to jail pretty much <a href="https://github.com/pigmonkey/spark/search?q=firejail">all the things</a>. Over the past six months, I&rsquo;ve found that one of my primary use cases for Firejail is to create private, temporary sandboxes which can be destroyed upon closure. I wrote <a href="https://github.com/pigmonkey/firewarden">Firewarden</a>, a simple wrapper script around Firejail, to reduce the keystrokes needed for this type of use.</p> <h2>Disposable Browsers</h2> <p>Prepend any program with <code>firewarden</code> and it will launch the program inside a private Firejail sandbox. I use Firewarden to launch disposable <a href="https://www.chromium.org/">Chromium</a> instances dozens of times per day. When the program passed to Firewarden is <code>chromium</code> or <code>google-chrome</code>, Firewarden will add the appropriate <a href="http://peter.sh/experiments/chromium-command-line-switches/">options</a> to the browser to prevent the first run greeting, disable the default browser check, and prevent the <a href="https://www.privacytools.io/webrtc.html">WebRTC IP leak</a>. The following two commands are equivalent:</p> <div class="highlight"><pre><span></span><code>$ firejail --private chromium --no-first-run --no-default-browser-check --enforce-webrtc-ip-permission-check $ firewarden chromium </code></pre></div> <p>Firewarden also provides a few options to request a more restricted Firejail sandbox. For instance, you may want to open a URL in Chromium, but also use an isolated network namespace and create a new <code>/dev</code> directory (which has the effect of disabling access to webcams, speakers and microphones). The following two commands are equivalent:</p> <div class="highlight"><pre><span></span><code>$ firejail --private --net<span class="o">=</span>enp0s25 --netfilter --private-dev chromium --no-first-run --no-default-browser-check --enforce-webrtc-ip-permission-check https://example.org $ firewarden -d -i chromium https://example.org </code></pre></div> <p>In this example, Firewarden used <a href="https://wiki.gnome.org/Projects/NetworkManager">NetworkManager</a> to discover that <code>enp0s25</code> was the first connected device, so it used that for the network namespace.</p> <h2>Local Files</h2> <p>Firewarden isn&rsquo;t just useful for browsers. It can be used with any program, but my other major use case is safely viewing local files. File types like PDF and JPG can include malicious code and are a primary vector for malware. I use <a href="https://pwmt.org/projects/zathura/">zathura</a> as my PDF reader, which is a simple and lightweight viewer that doesn&rsquo;t include anywhere near the number of potential vulnerabilities as something like Adobe Acrobat, but I still think it prudent to take extra precautions when viewing PDF files downloaded from the internet.</p> <p>If Firewarden thinks the final argument is a local file, it will create a new directory in <code>/tmp</code>, copy the file into it, and launch the program in a sandbox using the new temporary directory as the user home directory<sup class="footnote-ref" id="fnref:private-home"><a rel="footnote" href="#fn:private-home" title="see footnote">1</a></sup>. Firewarden will also default to creating a new <code>/dev</code> directory when viewing local files, as well as disabling network access (thus preventing a malicious file from phoning home). When the program has closed, Firewarden removes the temporary directory and its contents</p> <div class="highlight"><pre><span></span><code>$ firewarden zathura notatrap.pdf </code></pre></div> <p>The above command is the equivalent of:</p> <div class="highlight"><pre><span></span><code>$ <span class="nb">export</span> <span class="nv">now</span><span class="o">=</span><span class="sb">`</span>date --iso-8601<span class="o">=</span>s<span class="sb">`</span> $ mkdir -p /tmp/<span class="nv">$USER</span>/firewarden/<span class="nv">$now</span> $ cp notatrap.pdf /tmp/<span class="nv">$USER</span>/firewarden/<span class="nv">$now</span>/ $ firejail --net<span class="o">=</span>none --private-dev --private<span class="o">=</span>/tmp/<span class="nv">$USER</span>/firewarden/<span class="nv">$now</span> zathura notatrap.pdf $ rm -r /tmp/<span class="nv">$USER</span>/firewarden/<span class="nv">$now</span> </code></pre></div> <p>I use this functionality numerous times throughout the day. I also include Firewarden in <a href="https://github.com/pigmonkey/dotfiles/blob/master/mutt/mailcap">my mailcap</a>, which goes a long way to reducing the dangers of email attachments.</p> <p>Firewarden doesn&rsquo;t add any new functionality to Firejail, but it does make it easier to take advantage of some of the great features that Firejail provides. <a href="https://github.com/pigmonkey/firewarden">Check it out</a> if you&rsquo;re interested in reducing the keystrokes required to Jail All The Things&trade;.</p> <div id="footnotes"> <h2>Notes</h2> <ol> <li id="fn:private-home"><a rev="footnote" href="#fnref:private-home" class="footnote-return" title="return to article">&crarr;</a> This is similar to using Firejail's old <code>--private-home</code> option, which was <a href="https://l3net.wordpress.com/2016/02/04/firejail-0-9-38-release-announcement/">removed in 0.9.38</a>. However, that option was limited to files in the user's home directory. It couldn't be easily used with a file from a USB drive mounted at <code>/media/usb</code>, for instance.</li> </ol> </div>Using Network Trust2016-01-31T00:00:00-08:002019-01-04T17:00:53-08:00Pig Monkeytag:pig-monkey.com,2016-01-31:/2016/01/nmtrust/<p>Work continues on <a href="https://github.com/pigmonkey/spark">Spark</a>, my <a href="/2015/12/spark/">Arch Linux provisioning system</a>. As the project has progressed, it has created some useful tools that I&rsquo;ve spun off into their own projects. One of those is <a href="https://github.com/pigmonkey/nmtrust">nmtrust</a>.</p> <p>The idea is simple. As laptop users, we frequently connect our machines to a variety of …</p><p>Work continues on <a href="https://github.com/pigmonkey/spark">Spark</a>, my <a href="/2015/12/spark/">Arch Linux provisioning system</a>. As the project has progressed, it has created some useful tools that I&rsquo;ve spun off into their own projects. One of those is <a href="https://github.com/pigmonkey/nmtrust">nmtrust</a>.</p> <p>The idea is simple. As laptop users, we frequently connect our machines to a variety of networks. Some of those networks we trust, others we don&rsquo;t. I trust my home and work networks because I administer both of them. I don&rsquo;t trust networks at cafes, hotels or airports, but sometimes I still want to use them. There are certain services I want to run when connected to trusted networks: mail syncing, <a href="https://git-annex.branchable.com/">file syncing</a>, <a href="https://www.tarsnap.com/">online backups</a>, <a href="https://www.bitlbee.org/">instant messaging</a> and the like. I don&rsquo;t want to run these on untrusted networks, either out of concern over the potential leak of private information or simply to keep my network footprint small.</p> <p>The solution is equally simple. I use <a href="https://wiki.gnome.org/Projects/NetworkManager">NetworkManager</a> to manage networks. NetworkManager creates a profile for every network connection. Every profile is assigned a UUID. I can decide which networks I want to trust, lookup their UUID with <code>nmcli conn</code>, and put those strings into a file somewhere. I keep them in <code>/usr/local/etc/trusted_networks</code>.</p> <p><code>nmtrust</code> is a small shell script which gets the UUIDs of all the active connections from NetworkManager and compares them to those in the trusted network file. It returns a different exit code depending on what it finds: <code>0</code> if all connections are trusted, <code>3</code> if one or more connections are untrusted, and <code>4</code> if there are no active connections.</p> <p>This makes it extremely easy to write a script that executes <code>nmtrust</code> and takes certain action based on the exit code. For example, you may have a network backup script <code>netbackup.sh</code> that is executed every hour by cron. However, you only want the script to run when you are connected to a network that you trust.</p> <div class="highlight"><table class="highlighttable"><tr><td class="linenos"><div class="linenodiv"><pre><span class="normal">1</span> <span class="normal">2</span> <span class="normal">3</span> <span class="normal">4</span> <span class="normal">5</span> <span class="normal">6</span> <span class="normal">7</span> <span class="normal">8</span> <span class="normal">9</span></pre></div></td><td class="code"><div><pre><span></span><code><span class="ch">#!/bin/sh</span> <span class="c1"># Execute nmtrust</span> nmtrust <span class="c1"># Execute backups if the current connection(s) are trusted.</span> <span class="k">if</span> <span class="o">[</span> <span class="nv">$?</span> -eq <span class="m">0</span> <span class="o">]</span><span class="p">;</span> <span class="k">then</span> netbackup.sh <span class="k">fi</span> </code></pre></div></td></tr></table></div> <p>On machines running <a href="https://wiki.freedesktop.org/www/Software/systemd/">systemd</a>, most of the things that you want to start and stop based on the network are probably described by units. <code>ttoggle</code> is another small shell script which uses <code>nmtrust</code> to start and stop these units. The units that should only be run on trusted networks are placed into another file. I keep them in <code>/usr/local/etc/trusted_units</code>. <code>ttoggle</code> executes <code>nmtrust</code> and starts or stops everything in the trusted unit file based on the result.</p> <p>For example, I have a timer <code>mailsync.timer</code> that periodically sends and receives my mail. I only want to run this on trusted networks, so I place it in the trusted unit file. If <code>ttoggle</code> is executed when I&rsquo;m connected to a trusted network, it will start the timer. If it is run when I&rsquo;m on an untrusted network or offline, it will stop the timer, ensuring my machine makes no connection to my IMAP or SMTP servers.</p> <p>These scripts are easy to use, but they really should be automated so that nobody has to think about them. Fortunately, NetworkManager provides a dispatcher framework that we can hook into. When installed, <a href="https://github.com/pigmonkey/nmtrust/blob/master/dispatcher/10trust">the dispatcher</a> will execute <code>ttoggle</code> whenever a connection is activated or deactivated.</p> <p>The result of all of this is that trusted units are automatically started whenever all active network connections are trusted. Any other time, the trusted units are stopped. I can connect to shady public wifi without worrying about network services that may compromise my privacy running in the background. I can connect to my normal networks without needing to remember to start mail syncing, backups, etc.</p> <p>All of this is baked in to Spark, but it&rsquo;s really just two short shell scripts and a NetworkManager dispatcher. It provides a flexible framework to help preserve privacy that is fairly easy to use. If you use NetworkManager, <a href="https://github.com/pigmonkey/nmtrust">try it out</a>.</p>A Personal Micro-Cut Shredder2016-01-30T00:00:00-08:002016-01-30T21:10:11-08:00Pig Monkeytag:pig-monkey.com,2016-01-30:/2016/01/shred/<p>I purchased the <a href="http://www.amazon.com/dp/B008R52BRA">AmazonBasics 8-Sheet Micro-Cut Shredder</a> a few months ago. For the price I think it&rsquo;s a good buy. The CD shredding is a bit of a joke (use scissors), but it handles paper and cards admirably, cutting them into 4mm x 12mm pieces that will foil the …</p><p>I purchased the <a href="http://www.amazon.com/dp/B008R52BRA">AmazonBasics 8-Sheet Micro-Cut Shredder</a> a few months ago. For the price I think it&rsquo;s a good buy. The CD shredding is a bit of a joke (use scissors), but it handles paper and cards admirably, cutting them into 4mm x 12mm pieces that will foil the casual antagonist. The 8-sheet capacity, compact size, and low cost make it a good choice for personal document filing. Tis the season.</p> <p><a href="https://www.flickr.com/photos/pigmonkey/24628095331/in/dateposted/" title="Micro-Cut Shredder"><img src="https://farm2.staticflickr.com/1442/24628095331_57a1ff04bc_c.jpg" width="800" height="450" alt="Micro-Cut Shredder"></a></p>Financial Defense Through Proxies2015-12-29T00:00:00-08:002015-12-30T09:14:34-08:00Pig Monkeytag:pig-monkey.com,2015-12-29:/2015/12/proxy/<p><a href="http://krebsonsecurity.com/2015/12/2016-reality-lazy-authentication-still-the-norm/">Brian Krebs&rsquo; recent experience</a> highlights PayPal&rsquo;s insecurity. The convenience and ease of use of PayPal give them a wide customer base, but their inherent untrustworthiness has long been reason for concern. For as long as I&rsquo;ve used the service, I&rsquo;ve been concerned about external attacks, like what …</p><p><a href="http://krebsonsecurity.com/2015/12/2016-reality-lazy-authentication-still-the-norm/">Brian Krebs&rsquo; recent experience</a> highlights PayPal&rsquo;s insecurity. The convenience and ease of use of PayPal give them a wide customer base, but their inherent untrustworthiness has long been reason for concern. For as long as I&rsquo;ve used the service, I&rsquo;ve been concerned about external attacks, like what Krebs experienced, as well as the internal threat &ndash; PayPal themselves have <a href="http://www.paypalsucks.com/">a history of freezing and diverting their users&rsquo; funds</a>. Both of these concerns can be addressed via a proxy bank.</p> <p>In 2008 I opened an online checking account with a new bank, completely separate from the financial institutions I normally use. The account has no &ldquo;overdraft protection&rdquo; or any line of credit. As with my PayPal account, I keep no money in the checking account. This checking account is the only account I associate with PayPal. When I want to make a purchase via PayPal, I transfer the needed funds from my primary financial institution to the checking account at the proxy bank. Since banks still subscribe to the archaic notion of &ldquo;business days&rdquo;, this transfer can sometime take up to week, but more frequently completes within 2-3 days.</p> <p>The brief wait period is acceptable to me (it certainly reduces the ability to impulse buy) and gives me a level of security that otherwise cannot be achieved with PayPal. If someone breaks into my PayPal account, there&rsquo;s nothing for them to steal. Even PayPal themselves have limited ability to steal funds. If an attacker is lucky, they may gain access to the account when I&rsquo;m transferring funds in preparation for a purchase. My PayPal transactions are typically low-value, so at most this lucky attacker will acquire $100 or so. That&rsquo;s an acceptable risk for the convenience of PayPal.</p> <p>In the past I used this multilayer approach for all online purchases. A debit card from a proxy checking account at a different bank with no access to my primary accounts was the only thing I would use to make online purchases. When the account was compromised, the wait period for a new card wasn&rsquo;t the inconvenience it normally is, since it had no impact on my day-to-day spending with my primary accounts. I think this type of security is required for shopping online, but responsible use of a credit card can offer acceptable protection for non-PayPal transactions without the hassle of a proxy account.</p>Jailing the Browser2015-08-08T00:00:00-07:002015-08-08T12:11:26-07:00Pig Monkeytag:pig-monkey.com,2015-08-08:/2015/08/firejail/<p>The web browser is one of our computers&rsquo; primary means of interaction with the unwashed mashes. Combined with the unfortunately large attack surface of modern browsers, this makes a <a href="https://en.wikipedia.org/wiki/Sandbox_(computer_security)">sandbox</a> which does not depend on the browser itself an attractive idea.</p> <p><a href="https://l3net.wordpress.com/projects/firejail/">Firejail</a> is a simple, lightweight sandbox that uses <a href="https://lwn.net/Articles/531114/">linux …</a></p><p>The web browser is one of our computers&rsquo; primary means of interaction with the unwashed mashes. Combined with the unfortunately large attack surface of modern browsers, this makes a <a href="https://en.wikipedia.org/wiki/Sandbox_(computer_security)">sandbox</a> which does not depend on the browser itself an attractive idea.</p> <p><a href="https://l3net.wordpress.com/projects/firejail/">Firejail</a> is a simple, lightweight sandbox that uses <a href="https://lwn.net/Articles/531114/">linux namespaces</a> to prevent programs from accessing things they do not need.</p> <p>Firejail ships with default profiles for <a href="https://www.mozilla.org/en-US/firefox/new/">Firefox</a> and <a href="https://www.chromium.org/Home">Chromium</a>. These profiles drop <a href="https://l3net.wordpress.com/2015/03/16/firejail-linux-capabilities-guide/">capabilities</a>, filter <a href="https://l3net.wordpress.com/2015/04/13/firejail-seccomp-guide/">syscalls</a>, and prevent access to common directories like <code>/sbin</code>, <code>~/.gnupg</code> and <code>~/.ssh</code>. This is a good start, but I see little reason to give the browser access to much of anything in my home directory.</p> <p>The <code>--private</code> flag instructs Firejail to mount a new user home directory in a temporary filesystem. The directory is empty and all changes are discarded when the sandbox is closed &ndash; think of it as a more effective <a href="https://support.mozilla.org/en-US/kb/private-browsing-use-firefox-without-history">private browsing</a> or <a href="https://dev.chromium.org/user-experience/incognito">incognito</a> mode that also resets your browser to factory defaults.</p> <div class="highlight"><pre><span></span><code>$ firejail --private firefox </code></pre></div> <p>A more useful option for normal browsing is to specify a directory that Firejail should use as the user home. This allows you to keep a consistent browser profile and downloads directory, but still prevents the browser from accessing anything else in the normal user home.</p> <div class="highlight"><pre><span></span><code>$ mkdir ~/firefox $ mv ~/.mozilla ~/firefox/ $ firejail --private<span class="o">=</span>firefox firefox </code></pre></div> <p>This is the method I default to for my browsing. I&rsquo;ve created my own <a href="https://github.com/pigmonkey/dotfiles/blob/master/config/firejail/firefox.profile">Firejail profile for Firefox</a> at <code>~/.config/firejail/firefix.profile</code> which implements this.</p> <div class="highlight"><pre><span></span><code><span class="k">include</span><span class="w"> </span><span class="o">/</span><span class="nv">etc</span><span class="o">/</span><span class="nv">firejail</span><span class="o">/</span><span class="nv">disable</span><span class="o">-</span><span class="nv">mgmt</span>.<span class="nv">inc</span><span class="w"></span> <span class="nv">caps</span>.<span class="nv">drop</span><span class="w"> </span><span class="nv">all</span><span class="w"></span> <span class="nv">seccomp</span><span class="w"></span> <span class="nv">netfilter</span><span class="w"></span> <span class="nv">noroot</span><span class="w"></span> #<span class="w"> </span><span class="nv">Use</span><span class="w"> </span><span class="o">~/</span><span class="nv">firefox</span><span class="w"> </span><span class="nv">as</span><span class="w"> </span><span class="nv">user</span><span class="w"> </span><span class="nv">home</span><span class="w"></span> <span class="nv">private</span><span class="w"> </span><span class="nv">firefox</span><span class="w"></span> </code></pre></div> <p>The only inconvenience I&rsquo;ve discovered with this is that linking my <a href="http://www.vimperator.org/vimperator/">Vimperator</a> configuration files into the directory from my <a href="https://github.com/pigmonkey/dotfiles">dotfiles repository</a> creates a dangling link from the perspective of anything running within the jail. Since it cannot access my real home directory, it cannot see the link target in the <code>~/.dotfiles</code> directory. I have to copy the configuration files into <code>~/firefox</code> and then manually keep them in sync. I modify these files infrequently enough that for me this is worth the trade-off.</p> <p>The temporary filesystem provided by <code>--private</code> is still useful when accessing websites that are especially sensitive (such as a financial institution) or especially shady. In my normal browser profiles, I have a number of extensions installed that block ads, disable scripts, etc. If these extensions completely break a website, and I don&rsquo;t want to take the time to figure out which of the dozens of things I&rsquo;m blocking are required for the website to function, I&rsquo;ll just spin up a sandboxed browser with the <code>--private</code> flag, comfortable in the knowledge that whatever dirty scripts the site is running are limited in their ability to harm me.</p> <p>I perform something like 90% of my web browsing in Firefox, but use Chromium for various tasks throughout the day. Both run in Firejail sandboxes, helping to keep me safe when surfing the information superhighway. Other programs, like torrent applications and PDF readers, also make good candidates for running within Firejail.</p>I wrote an article about anonymous debit cards on ITS Tactical.2013-04-23T00:00:00-07:002013-04-23T00:00:00-07:00Pig Monkeytag:pig-monkey.com,2013-04-23:/2013/04/prepaid/<p>I have previously mentioned <a href="/2012/11/simon-provides-anonymous-debit-cards/">prepaid debit cards</a>. On <a href="http://www.itstactical.com/">ITS</a> I discuss using <a href="http://www.itstactical.com/digicom/privacy/how-to-use-prepaid-debit-cards-for-anonymous-cash-like-digital-transactions/">prepaid debit cards for anonymous, cash-like digital transactions</a> a bit more in-depth.</p>Simon provides anonymous debit cards.2012-11-09T00:00:00-08:002012-11-09T00:00:00-08:00Pig Monkeytag:pig-monkey.com,2012-11-09:/2012/11/simon-provides-anonymous-debit-cards/<p>Their prepaid Visa and American Express gift cards can be purchased with cash at any <a href="https://www.simon.com/mall">Simon mall</a>. No identification is required. To use the card with online merchants, you will likely need to <a href="https://www.simon.com/giftcard/">register the card</a> with an address so that it can pass <a href="https://en.wikipedia.org/wiki/Address_Verification_System">AVS</a> checks. This can be done …</p><p>Their prepaid Visa and American Express gift cards can be purchased with cash at any <a href="https://www.simon.com/mall">Simon mall</a>. No identification is required. To use the card with online merchants, you will likely need to <a href="https://www.simon.com/giftcard/">register the card</a> with an address so that it can pass <a href="https://en.wikipedia.org/wiki/Address_Verification_System">AVS</a> checks. This can be done through <a href="https://www.torproject.org/">Tor</a> with fake information.</p> <p><a href="http://www.flickr.com/photos/pigmonkey/8170700003/" title="Anonymous Debit Card by Pig Monkey, on Flickr"><img src="https://farm9.staticflickr.com/8209/8170700003_4c97dfbaa0_c.jpg" width="800" height="534" alt="Anonymous Debit Card"></a></p>Leave My Keys Alone2007-12-16T00:00:00-08:002012-09-15T00:00:00-07:00Pig Monkeytag:pig-monkey.com,2007-12-16:/2007/12/leave-my-keys-alone/<p>Judge rules defendant can&rsquo;t be forced to divulge PGP passphrase</p> <blockquote>A federal judge in Vermont has ruled that prosecutors can't force a criminal defendant accused of having illegal images on his hard drive to divulge his PGP (Pretty Good Privacy) passphrase. U.S. Magistrate Judge Jerome Niedermeier ruled that …</blockquote><p>Judge rules defendant can&rsquo;t be forced to divulge PGP passphrase</p> <blockquote>A federal judge in Vermont has ruled that prosecutors can't force a criminal defendant accused of having illegal images on his hard drive to divulge his PGP (Pretty Good Privacy) passphrase. U.S. Magistrate Judge Jerome Niedermeier ruled that a man charged with transporting child pornography on his laptop across the Canadian border has a Fifth Amendment right not to turn over the passphrase to prosecutors. The Fifth Amendment protects the right to avoid self-incrimination. Niedermeier tossed out a grand jury's subpoena that directed Sebastien Boucher to provide "any passwords" used with the Alienware laptop. "Compelling Boucher to enter the password forces him to produce evidence that could be used to incriminate him," the judge wrote in an order dated November 29 that went unnoticed until this week. "Producing the password, as if it were a key to a locked container, forces Boucher to produce the contents of his laptop."</blockquote>