title: Reverse engineering Google "Write a Review" link URLs
body: <p>In Google local listings, there is a URL that can take a person directly to the pop-up window showing the reviews of a business.  Here is an example:</p>
  
  <p><a href="https://www.google.com/search?q=Massage+Envy+-+Arrowhead&amp;ludocid=12682026813239828050#lrd=0x872b682580f9e59b:0xafff9c31c3239e52,1" rel="nofollow">https://www.google.com/search?q=Massage+Envy+-+Arrowhead&amp;ludocid=12682026813239828050#lrd=0x872b682580f9e59b:0xafff9c31c3239e52,1</a></p>
  
  <p>Each business location has a numeric ID in the URL (in the example, 12682026813239828050) as well as a hexadecimal representation of this number in the <code>#lrd</code> parameter.</p>
  
  <p>I have all of the numeric IDs, and need to generate these URLs by determining how the hexadecmial segment is formed.  For locations with IDs that can be represented in 16 hex characters, this is easy.  The URL segment is simply 0x0:0x[hexstring] for example:</p>
  
  <pre><code>4134566830992571874 =&gt; 0x0:0x3960eea07d6cbe00
  </code></pre>
  
  <p>But when the number is too long, it is broken into two hex strings, and I can't determine the origin of the first one.  I pulled in 2 examples:</p>
  
  <pre><code>14384749138104818286 =&gt; 0x872b0445e4ee5e9b:0xc7a0e5209fd81a6e
  15716027411522919173 =&gt; 0x872b00074aa36265:0xda1a8ba9e8201b05
  </code></pre>
  
  <p>The SECOND hex string converts to a number that is CLOSE.  In the examples:</p>
  
  <pre><code>c7a0e5209fd81a6e =&gt; 14384749138104818 (missing the last 3 digits)
  da1a8ba9e8201b05 =&gt; 15716027411522918 (missing the last 3 digits and off by 1000)
  </code></pre>
  
  <p>Here is a site that is successfully converting them: <a href="https://pleper.com/index.php?do=tools&amp;sdo=google_review_link&amp;url=4134566830992571874" rel="nofollow">https://pleper.com/index.php?do=tools&amp;sdo=google_review_link&amp;url=4134566830992571874</a></p>
  
  <p>Can anyone help me determine the method by which these are being generated?  If there is another stack site that would be better for this please direct me there as well.  Thank you!</p>