We are sure that there are no brown dwarfs closer than ______ I don't quite know how to word this question.

How close could a brown dwarf be to us and have gone undetected until now?

Or maybe, with what probability are we sure that there is no brown dwarf within X light years of the sun? (For different values of X)

(Don't worry about addressing Nemesis or a hypothetical binary partner for the sun. I'm just asking about undetected brown dwarfs..., even outside of the Oort cloud but within Alpha C. I don't know how sensitive the WISE survey was.)
I think the answer is roughly 3-5 light years.

The recent WISE survey in the near-infrared should have been capable of detecting even a very cool nearby brown dwarf (and indeed it has detected some very cool brown dwarfs - e.g. a 250K brown dwarf only 6 light years away Luhman et al. 2014). Since WISE was an all-sky survey and there is great interest in finding these ultracool brown dwarfs, then it is reasonable to assume that any similar, object within a few light years would already have been found. The caveat to this is that the point spread function of the WISE survey s not that great an so near the galactic plane it could be that source confusion might have hidden the brown dwarf. On the other hand, nearby objects usually have high proper motion, so it would probably have been uncovered in combination with the earlier 2MASS survey, since as I show below, such an object may have been detected in both.

Some details: As an example let's take a very low mass brown dwarf - say 20 Jupiter masses and 5 billion years old - and place it 4 light years from the Sun. According to the evolutionary models of Saumon &amp; Marley (2008), such an object has an intrinsic luminosity of $10^{-7}$ times (1 ten millionth) that of the Sun and a temperature of 400 Kelvin and would appear to have a spectral type of late T or early Y. This is similar to the coolest brown dwarfs yet found. 

From the calibration of absolute magnitudes versus spectral type for cool brown dwarfs in Marsh et al. (2013) we know that at 4 light years, such a brown dwarf would have magnitudes of $H=16$ and $W2=10$. The former is just about bright enough to have been seen in the 2MASS all-sky survey and the latter is easily detected by WISE. The combination of data would also easily have revealed the large parallax of such an object. We can conclude that an object would have to have much lower mass than this to remain undetected and thus would arguaby not be called a brown dwarf, but would really be a "free-floating planet".

Now you might ask, what about a cooler brown dwarf? Well the theoretical predictions of magnitudes and colours become much more uncertain, but I would simply refer to the Luhman discovery. This brown dwarf is about as cool as a brown dwarf could be given the age of the Galaxy, may only be 10 Jupiter masses, yet was still easily detected in the WISE survey. Therefore I think this sets a fairly firm empirical limit.