Code Monkey home page Code Monkey logo

Comments (12)

MachineITSvcs avatar MachineITSvcs commented on May 25, 2024 1

Just a suggestion. You may consider using only +short instead of +noall +answer, as it will provide you only with the nameservers. It may also be worth mentioning that if the server is set up as listed nameservers, should we proceed with adding the domain. An example would be if I'm already pointing the domain from the registrar to the server, but it's not yet setup in ISPConfig. Maybe having an option where you can specify "whitelisted" nameservers may be beneficial. So if they are found, one or more, in any order, but without additional nameservers, the operation proceeds.

dig +short <domain> NS

from wp-ispconfig3.

ole1986 avatar ole1986 commented on May 25, 2024

But still, when its registered to a nameserver it would be unavailable. No matter if its your own nameserver or any other, right?

from wp-ispconfig3.

MachineITSvcs avatar MachineITSvcs commented on May 25, 2024

from wp-ispconfig3.

MachineITSvcs avatar MachineITSvcs commented on May 25, 2024

Obviously, you'd still want to make sure it's not already being used for a site by another user, but you already built the function for that

from wp-ispconfig3.

MachineITSvcs avatar MachineITSvcs commented on May 25, 2024

What I'm trying to say is, if you own the domain (or it's been purchased before), then this check will always fail, UNLESS you manually delete all the nameservers of the domain in the registrar. Best to just check them for the right nameservers.

from wp-ispconfig3.

ole1986 avatar ole1986 commented on May 25, 2024

Ok, I got it. But wouldn't it be still more useful to whitelist domain names instead of name servers?

Imaging you have a NS which contain both. A domain which is already in used by a customer and another domain which is parked only. Then both will available due to the whitelisted name server.

BTW: Buying web domain sounds like a job for the other plugin wc-invoice-pdf. The name might be confusing but it takes the woocommerce orders into account and also comes up with a Webspace product for woocommerce.

If you need an individual product for only buying web domain it can quickly be arranged I think. Just checkout the other plugin page and raise an issue (if needed)

from wp-ispconfig3.

MachineITSvcs avatar MachineITSvcs commented on May 25, 2024

from wp-ispconfig3.

ole1986 avatar ole1986 commented on May 25, 2024

ATM it can either validate against the global (using whois and dig command) or against the ISPConfig database if a domain is available. But not both at the same time.

So would you agree to the following future change (quick draw):

File deleted, needs review

from wp-ispconfig3.

ole1986 avatar ole1986 commented on May 25, 2024

Regarding the other plugin feature, feel free add an issue there for name.com integration. highly appreciated

from wp-ispconfig3.

MachineITSvcs avatar MachineITSvcs commented on May 25, 2024

I feel it would be easier to whitelist nameservers when using the whois check, if enabled, and if available or whitelisted nameservers received, then proceed as if available IF domain also available in ISPConfig3 database.

Construct:
Begin Domain Check --> Check ISPConfig3 Database --> IF Database DOES contain domain (End Domain Check Returning as Unavailable), ELSE Check Nameservers using Dig --> IF Nameservers NOT Received (End Domain Check Returning as Available), Else IF Nameservers Received (Check whitelisted nameservers against Nameservers Received, IF whitelisted (End Domain Check, Returning Domain as Available), Else (End Domain Check, Returning Domain as Unavailable))

Forgive my pseudo-code.

The main priority should be to make sure the domain does not already exist in the ISPConfig3 Database, to prevent duplicate sites or DNS zone from being created, or throwing errors. If the domain is not in the database already, you should then check if it's nameservers are set via dig and if those Nameservers are whitelisted before adding them to the database.

from wp-ispconfig3.

MachineITSvcs avatar MachineITSvcs commented on May 25, 2024

So just to clarify, are you now checking whether domains being checked are whitelisted or their nameservers?

from wp-ispconfig3.

ole1986 avatar ole1986 commented on May 25, 2024

As already mentioned here when using name servers it may result in false positive results

That is why domain names makes more sense and are taken for the whitelist

from wp-ispconfig3.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.