πŸ” eShram – Aadhaar Auto Encrypt & API Call

Enter your 12-digit Aadhaar number – it will be encrypted in real-time and the API response will appear below.

⏳ Processing...

βš™οΈ One‑time setup – Get the real encryption function automatically

Follow these steps exactly. It takes only 2 minutes.

Step 1: Open register.eshram.gov.in in a new tab.
Step 2: Press F12 to open Developer Tools, then click on the Console tab.
Step 3: Copy the entire script below and paste it into the Console, then press Enter.

// ===== RUN THIS IN CONSOLE ON eSHRAM WEBSITE =====
(function() {
  let func = null;
  for (let key in window) {
    try {
      if (typeof window[key] === 'function' && window[key].toString().includes('aadhaar')) {
        func = window[key];
        break;
      }
    } catch(e) {}
  }
  if (!func) {
    // Try searching inside minified scripts
    const scripts = document.getElementsByTagName('script');
    for (let s of scripts) {
      if (s.textContent.includes('encrypt') && s.textContent.includes('aadhaar')) {
        const match = s.textContent.match(/function\s+(\w+)\s*\([^)]*\)\s*\{[^}]*\}/);
        if (match) {
          func = new Function('return ' + match[0])();
          break;
        }
      }
    }
  }
  if (func) {
    console.log('βœ… Real encryption function found:');
    console.log(func.toString());
    console.log('πŸ“‹ Copy the above function and paste it into the "encryptAadhaar" function in the PHP file.');
  } else {
    console.log('❌ Could not auto-detect. Try searching manually for "encrypt" in Sources tab.');
  }
})();
Step 4: The console will print the real encryption function. Copy that entire function (from function to the closing }).
Step 5: Come back to this page, find the dummy function below, and replace it with the real one. Save the file.
🎯 That's it! After replacing, every Aadhaar you enter will be encrypted with the real method and you'll get the correct API response.
πŸ“ Current encryption function (replace this with the real one):
function encryptAadhaar(plain) {
    // ====== THIS IS A DUMMY – REPLACE WITH REAL FUNCTION ======
    // It always returns a known encrypted string (from your capture)
    return "a4d2a3345db4cdfda4eaece771d8cbead2cd461e78ddf5672a5c0e4f800e1ecaeab329b53d865a37b6952e8f853f7a6c64f51c7812196b86fd72b3a3782da6e38a1a6ce2bfedc6dd5dd5d7e4696277e50e2fe3a270116ac02df235bfdeaf3cef721c1ed860f03e12f4a646ba99567d2321000e174c1c657e5e25dafb74430762";
}

πŸ”΄ After you get the real function from the console, paste it over this dummy.