title: Firebase Rules allows read but does not allow write
body: <pre><code>"display": {
        ".read": "auth != null",
        ".write": "auth != null",
          "abc": {
            ".indexOn": ["hhh"],
            "$display_id": {
              "aaa": {".validate": "newData.isString() &amp;&amp; newData.val().length &gt; 0"},
              "bbb": {".validate": "newData.isString() &amp;&amp; newData.val().length &gt; 0"},
              "ccc": {".validate": "newData.isString() &amp;&amp; newData.val().length &gt; 0"},
              "ddd": {".validate": "newData.isString() &amp;&amp; newData.val().length &gt; 0"},
              "eee": {".validate": "newData.isString() &amp;&amp; newData.val().length &gt; 0"},
              "fff": {".validate": "newData.isString() &amp;&amp; newData.val().length &gt; 0"},
              "ggg": {".validate": "newData.isString() &amp;&amp; newData.val().length &gt; 0"},
              "hhh": {".validate": "newData.isString() &amp;&amp; newData.val().length &gt; 0"},
              "iii": {".validate": "newData.isString() &amp;&amp; newData.val().length &gt; 0"},
              "jjj": {".validate": "newData.isString() &amp;&amp; newData.val().length &gt; 0"},
              "kkk": {".validate": "newData.val() == $display_id"},
              "lll": {".validate": "newData.isNumber()"},
              "$others": {".validate": false}
              }
          }
  }
  </code></pre>
  
  <p>The above code is a snippet of one of my path rules in the Firebase Database Rules section.</p>
  
  <p>Just for reference, <code>display_id</code> is a pushed value and <code>lll</code> is a long which is obtained from <code>calendar.getTimeInMillis()</code>.</p>
  
  <p>I have been trying to find the solution for this for a long time and I’m on the verge of giving up.</p>
  
  <p>These are my few observations up until now.</p>
  
  <ol>
  <li>There are no <code>.read</code> or <code>.write</code> above the “display” in the rule tree, so there should not be any cascading errors regarding reading or writing the data.</li>
  <li>There shouldn’t be any problems in my App’s java class model since I can read the data fine</li>
  <li>There shouldn’t be any authentication errors since I can read the data with <code>auth != null</code></li>
  <li>There should not be any annotation errors as the rules applet does not give me any errors at the moment</li>
  </ol>
  
  <p>I’m lost. When I write data to this node through my app, I keep getting Permission Denied.</p>
  
  <p>Any thoughts?</p>