title: Bitcoind JSON RPC auth not working
body: <p>I have runing bitcoind on ubuntu. bitcoin-cli works fine. I can not get working json rpc protocol</p>
  
  <p>bitcoin.conf file:</p>
  
  <pre><code>testnet=0
  rpcuser="bitcoinrpc"
  rpcpassword="xxxxx"
  rpcport=8332
  rpcallowip="*"
  server=1
  </code></pre>
  
  <p>http post request with url='<a href="http://bitcoinrpc:xxxxx@127.0.0.1:8332/" rel="nofollow">http://bitcoinrpc:xxxxx@127.0.0.1:8332/</a>' fails with 401 error.</p>
  
  <p>request headers:</p>
  
  <pre><code>Accept:*/*
  Accept-Encoding:gzip, deflate
  Accept-Language:en-US,en;q=0.8,ru;q=0.6,de;q=0.4,sr;q=0.2
  Authorization:Basic Yml0Y29pbnJwYzp4eHh4eA==
  Cache-Control:no-cache
  Connection:keep-alive
  Content-Length:53
  Content-Type:text/plain
  DNT:1
  Host:127.0.0.1:8332
  Origin:chrome-extension://fhjcajmcbmldlhcimfajhfbgofnpcjmb
  Pragma:no-cache
  User-Agent:Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Ubuntu Chromium/51.0.2704.79 Chrome/51.0.2704.79 Safari/537.36
  </code></pre>
  
  <p>request post payload:</p>
  
  <pre><code>{jsonrpc: "2.0", method: "getinfo", params: []}
  </code></pre>
  
  <p>What is correct way for bitcoind json rpc autentification?</p>