Do http basic auth by the book

I'll rebase this later today and then it should be ok to merge
And I'll make check the latest NB plugin version also