An excellent essay. For the non-technical, his conclusion is the most important:
Everything we've seen about QUANTUM and other internet activity can be replicated with a surprisingly moderate budget, using existing tools with just a little modification.
The biggest limitation on QUANTUM is location: The attacker must be able to see a request which identifies the target. Since the same techniques can work on a Wi-Fi network, a $50 Raspberry Pi, located in a Foggy Bottom Starbucks, can provide any country, big and small, with a little window of QUANTUM exploitation. A foreign government can perform the QUANTUM attack NSA-style wherever your traffic passes through their country.
And that's the bottom line with the NSA's QUANTUM program. The NSA does not have a monopoly on the technology, and their widespread use acts as implicit permission to others, both nation-state and criminal.
Moreover, until we fix the underlying Internet architecture that makes QUANTUM attacks possible, we are vulnerable to all of those attackers.
(This entry is part of a series. The audience: SQL Server developers. The topic: SQLite on mobile devices.)
I can't use SQLite! It doesn't support foreign keys!
Actually, it does. Since version 3.6.19, released in October 2009. Before
the first iPad. Windows 7 was not quite out yet.
Miley Cyrus was still Hannah Montana.
You're wrong! This code should fail but doesn't!
CREATE TABLE [to] (pk int PRIMARY KEY);
CREATE TABLE [from] (other REFERENCES [to](pk) );
INSERT INTO [from] (other) VALUES (3);
Fair enough. It is easy to get the impression that SQLite still lacks
support for foreign keys because the feature is [usually] turned off by default, to preserve
How to turn SQLite foreign key support on
To enable the enforcement of foreign key constraints, execute the following SQL statement, shortly
after you open your SQLite database connection:
PRAGMA foreign_keys = 1;
I always use SQLite with foreign keys. In fact, I always open SQLite
connections with a helper function
which (1) opens the SQLite connection and (2) immediately executes the PRAGMA
Once you've got the feature turned on, foreign key support in SQLite is generally
similar to what a SQL Server dev would expect. Full documentation is available on the SQLite website, but there are a few things worth highlighting.
SQLite supports simple foreign keys (with one column referencing one
column), or composite foreign keys (with multiple columns referencing
SQLite does support ON DELETE and ON CASCADE.
SQLite allows a foreign key constraint to be deferred, which
means that its enforcement is postponed until the transaction is committed.
This is a handy feature that I really wish SQL Server had.
The IFileOperation interface accepts bulk operations
in the form of an IShellItemArray.
So how do you take a list of file names and convert them
There is no
function, but there is a
and we know how to convert a path to an ID list,
snap two blocks together.
template function takes an array of paths and starts by creating
a corresponding array of ID lists.
(If you're feeling fancy, you can
use a file system bind context to make simple ID lists.)
It then pumps this array into the
function to get the item array.
Using a template allows you to pass an array of anything
as the array of paths, as long as it has a conversion to
So you can pass
an array of PCWSTR or
an array of PWSTR or
an array of BSTR or
an array of CComHeapPtr<wchar_t> or
an array of CStringW
or whatever else floats your boat.
The main program first treats the command line arguments
as a list of absolute file paths
and uses our new helper function to create a shell item array
It then passes the shell item array to the
to delete all the items.
No magic here.
Just taking the pieces available and combining them in a
relatively obvious way.