question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

`domainLock` not working

See original GitHub issue

I’m unable to use the domainLock config. I get data is not defined whenever I use it.

Expected Behavior

I expect passing a list of domain names to domainLock to lock the obfuscated scripts to those domains.

Current Behavior

Passing any domains to domainLock makes the script throw data is not defined regardless of what domain it’s visited on.

Steps to Reproduce (for bugs)

Using javascript-obfuscator version 0.15 or 0.16, obfuscate the script with the following options:

const OBFUSCATION_OPTIONS = {
  domainLock: ['.examplea.com', '.exampleb.com'],
};

Finally, run a web server and point examplea.com or exampleb.com to localhost in your /etc/hosts file then try to load the script in an html file.

EDIT: This is also reproducible on https://obfuscator.io. If you obfuscate the sample script and lock it to .obfuscator.io then try to evaluate it, it’ll fail.

Your Environment

  • Version used: 0.15 and 0.16

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Comments:9 (4 by maintainers)

github_iconTop GitHub Comments

1reaction
sanex3339commented, Jun 27, 2018

0.17.0 version in out!

1reaction
sanex3339commented, May 18, 2018

Reproduced it. Will fix it soon.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Change your domain lock setting - Google Support
Click Registration settings. Scroll down to Domain lock. Toggle Lock domain / Unlock domain to change the domain's lock setting. Restrictions for domain...
Read more >
About Locked Domain - ICANN
Domain names can be locked to protect against unauthorized changes. This status may be called "Registrar lock" or "Client Transfer Prohibited" (or a...
Read more >
Domain Security: How To Unlock A Domain
On the dashboard, select the domain you are working on. ... Toggle the Domain Lock to Green or to the Right. Domain lock...
Read more >
Why is my domain locked for 60 days?
If your domain's registrar is a third-party (such as GoDaddy or Google), some providers will lock your domain for 60 days if you...
Read more >
Why Is Domain Locked & Where To Unlock It? - Monsterhost
What causes domains to lock? · 1. Domains expire · 2. Domain Age · 3. Change Registrant · 4. Legal Issues.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found