Why you shouldn’t use Google Authenticator

For some time I have been using 2FA as much as possible, to secure various logins and accounts.

The app I have been using for it is Google Authenticator on Android. This was because the first time I used 2FA was on starting a new job, and it was what the company was using for OpenVPN and Xero. It all seemed simple enough – when setting up an account on a site it showed me a QR code and I scanned it with the phone. Then to login I would just type in the number currently shown in the phone app for that site.

All worked fine for a couple of years until a hardware fault completely bricked my phone. Without ever checking, I had assumed that Google had backed up the codes it needed and I could just log into my Google account and have them loaded into the app on my new phone. Turns out that that is not the case, and there is no way of backing up Google Authenticator at all. On getting a new phone you can transfer codes across, but that’s all. If you don’t have old phone, that obviously can’t be done.

Continue reading “Why you shouldn’t use Google Authenticator”

Converting to Nextcloud Contacts and Calendars

I recently bought a Syncloud Cloud server, primarily so that I, my girlfriend and my band could all have large dropboxes and shared dropboxes without each having to pay large regular fees to a cloud company. The dropbox facilities the Nextcloud server on it provides are similar to those of Dropbox, but Nextcloud also has a wide range of apps that can be installed to provide more cloud facilities.

Among them are Contacts and Calendar apps, which I decided to install and convert to in order to reduce the amount of information that Google can trawl about me. To consider them working I needed to get both to operate in the Nextcloud web interface, Thunderbird (on Windows, but that is probably not relevant) and Android phone and tablets.

Continue reading “Converting to Nextcloud Contacts and Calendars”

Windows 7 Update Problems

I’ve had problems for a while with Windows Update failing on Windows 7 VMs. The result is that the Windows Update service uses 100% of CPU (or 50% with 4 cores) and completely locks everything else out for minutes at a time, without ever installing anything. I’ve been getting around it by disabling the Windows Update service, but decided I had better get it working. After a bit of hunting around, I found the explanation and a fix that actually works at http://www.askvg.com/fix-windows-7-keeps-checking-for-updates-for-hours/ Continue reading “Windows 7 Update Problems”

Linux and Xamarin socket problems

One of the requirements I set myself for my Socket library was that it should be as robust as possible about knowing that the other end of a connection had gone away. The .net socket objects are pretty bad for this, and the only way to be certain that the connection is up is to attempt to read or write its data stream. Continue reading “Linux and Xamarin socket problems”

Dropbox support for Xamarin.Forms

The new Dropbox v2 API makes it quite straightforward to add support for Dropbox into an app running on a phone or tablet. When I decided to add Dropbox support to Mobile DMX it quickly became obvious, looking at the “SimpleTest” sample app, that the awkward part is logging in, but uploading and downloading small files would then be very easy. Continue reading “Dropbox support for Xamarin.Forms”

Xamarin.Forms Error CS0117

Now that I have completed the first release of Mobile DMX I thought would convert the project over from Xamarin Studio to Visual Studio. I wasn’t able to do this until recently because I have an “Indie Android” licence, which meant I had to use Xamarin Studio, but since MS have bought Xamarin I can now use Visual Studio (Xamarin Studio is deprecated), which is good.

Took a while, though. At first I was getting several hundred errors of the form

error CS0117: 'Resource.Attribute' does not contain a definition for 'mediaRouteSettingsDrawable'

Continue reading “Xamarin.Forms Error CS0117”

Fun with Sockets

Actually, not fun at all. This problem has been driving me nuts for hours.

There are some things I like about .net socket programming, but one thing that always causes horrible problems is shutting sockets down when I’ve finished with them. One way or another, I always end up having to trap some exceptions. Continue reading “Fun with Sockets”

Incorporating MS Identity database into an application database

I’ve just started writing my first serious .NET MVC application. It’s intended to be a slightly cut-down web version of Calibre, supporting only epub format (at least, initially). It has a SQL Server database where everything is stored, and will allow the user to upload epubs, then extract metadata from them, and put it all into database records organised by user. All properly normalised, of course, so that if, for example, two users upload the same epub file it will only store one copy. Continue reading “Incorporating MS Identity database into an application database”

The VS IDE, the FTD2XX dll, the mouse, the keyboard, and a dent in a brick wall

I’m just starting a project that involves talking to a board with an FT245R USB interface. I’ve got an XP VM set up with VS 2010 (some target machines will be running XP), the FTD2XX dll, the C# interface code published by FTDI, and some working VB6 code to get started with.

All seemed straightforward-ish. The first thing I had to do was rewrite the C# interface code to take out the message boxes it popped up when there were errors, and change it so that it throws exceptions instead of returning statuses that have to be checked for every call. It uses a somewhat bizarre and long winded way of referencing the functions in the dll, getting function pointers and marshalling them to delegates as they are used (rather than just using extern declarations), but it works so I left it.

Next thing was to create a Windows Forms app, and open the USB device using its description. Worked straight away. Excellent. Put some buttons on the form and run it again. Didn’t work – failed to open the device. That happened repeatedly, so I tried running the VB program. That worked, then running the app again worked. Then it didn’t. Continue reading “The VS IDE, the FTD2XX dll, the mouse, the keyboard, and a dent in a brick wall”