title: How do I change my iOS applications' entitlements?
body: <p>I need to run the following code to turn off my iphone screen .</p>
  
  <p>On iOS6:</p>
  
  <pre><code>void (*BKSDisplayServicesSetScreenBlanked)(BOOL blanked) = (void (*)(BOOL blanked))dlsym(RTLD_DEFAULT, "BKSDisplayServicesSetScreenBlanked");
  </code></pre>
  
  <p>and then use:</p>
  
  <pre><code>BKSDisplayServicesSetScreenBlanked(1); // 1 to dim, 0 to undim
  </code></pre>
  
  <p>It doesnt work.  Somebody told me that I  need <code>com.apple.backboard.client</code> entitlements for this to work on my iphone.  I dont know how to set these entitlements. I have seen several ways to set entitlements but they are very confusing to me, like this one.</p>
  
  <blockquote>
    <p>Yes, you do need to code sign the entitlements. But, no, it doesn't
    have to be with an Apple certificate on jailbroken phones. You can
    fake code sign, by downloading the ldid executable, and doing</p>
  
  <pre><code>cd MyAppName.app 
  ldid -Sentitlements.xml MyAppName
  </code></pre>
    
    <p>assuming your app is named MyAppName and you made the entitlements
    file entitlements.xml. I believe that this entitlements file would
    work for you, if you fake code-signed it with ldid.</p>
  </blockquote>
  
  <pre class="lang-xml prettyprint-override"><code>&lt;!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN"
   "http://www.apple.com/DTDs/PropertyList-1.0.dtd"&gt; &lt;plist version="1.0"&gt;
     &lt;dict&gt;
       &lt;key&gt;com.apple.backboard.client&lt;/key&gt;
       &lt;true/&gt;
     &lt;/dict&gt; 
  &lt;/plist&gt;
  </code></pre>
  
  <p>Even with the above method, where do i place the above entitlements file?</p>