title: Error: 403 Forbidden while pushing/pulling images to/from docker
body: <p><br>
  I am using <strong>docker server version : 1.10.3</strong>  with docker distribution installed on <strong>RHEL 7.2</strong> <br>
  The issue i am facing is an intermittent one. Some times the push/pull commands works and some times they throw below error:</p>
  
  <pre><code>Pulling repository test.a.b.c.com/hello-world
  Error: Status 403 trying to pull repository hello-world: "&lt;!DOCTYPE HTML PUBLIC \"-//IETF//DTD HTML 2.0//EN\"&gt;\n&lt;html&gt;&lt;head&gt;\n&lt;title&gt;403 Forbidden&lt;/title&gt;\n&lt;/head&gt;&lt;body&gt;\n&lt;h1&gt;Forbidden&lt;/h1&gt;\n&lt;p&gt;You don't have permission to access /v1/repositories/hello-world/images\non this server.&lt;br /&gt;\n&lt;/p&gt;\n&lt;/body&gt;&lt;/html&gt;\n"
  </code></pre>
  
  <p>The output of  " <strong>sudo service docker status</strong>" is: </p>
  
  <pre><code>Aug 15 11:04:48 server forward-journal[6535]: time="2016-08-15T11:04:48.866644712+02:00" level=error msg="Handler for POST /v1.22/images/create returned error: invalid reference format"
  Aug 15 21:40:05 server forward-journal[6535]: time="2016-08-15T21:40:05.558387849+02:00" level=info msg="{Action=build, LoginUID=4294967295, PID=17431}"
  Aug 15 21:40:23 server forward-journal[6535]: time="2016-08-15T21:40:23.346912366+02:00" level=info msg="{Action=push, LoginUID=4294967295, PID=17452}"
  Aug 15 21:40:23 server forward-journal[6535]: time="2016-08-15T21:40:23.426768722+02:00" level=error msg="Upload failed: Error parsing HTTP response: unexpected end of JSON input: \"\""
  Aug 15 21:40:23 server forward-journal[6535]: time="2016-08-15T21:40:23.428789638+02:00" level=error msg="Upload failed: Error parsing HTTP response: unexpected end of JSON input: \"\""
  Aug 15 22:36:05 server forward-journal[6535]: time="2016-08-15T22:36:05.122054012+02:00" level=info msg="{Action=build, LoginUID=4294967295, PID=22228}"
  Aug 15 22:36:16 server forward-journal[6535]: time="2016-08-15T22:36:16.022509441+02:00" level=info msg="{Action=push, LoginUID=4294967295, PID=22247}"
  Aug 16 07:17:45 server forward-journal[6535]: time="2016-08-16T07:17:45.608893675+02:00" level=info msg="{Action=create, Username=test, LoginUID=877601153, PID=978}"
  Aug 16 07:18:24 server forward-journal[6535]: time="2016-08-  16T07:18:24.768737515+02:00" level=info msg="{Action=push, Username=test, LoginUID=877601153, PID=1081}"
  Aug 16 07:20:15 server forward-journal[6535]: time="2016-08-16T07:20:15.546273448+02:00" level=info msg="{Action=create, Username=test, LoginUID=877601153, PID=1273}"
  </code></pre>
  
  <p>Could anyone explain why is it so?  Why do I get 403 forbidden issue even though I have rights. <br> 
  Why it works sometimes and doesn't sometimes?</p>