Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Infinite loop on some dates/times #92

Open
e7o-de opened this issue Mar 14, 2022 · 11 comments
Open

Infinite loop on some dates/times #92

e7o-de opened this issue Mar 14, 2022 · 11 comments

Comments

@e7o-de
Copy link

e7o-de commented Mar 14, 2022

The loop in whois.parser.php#L910 runs infinitely for values like

Creation Date: 2021-07-19T13:03:01.00Z

A print_r($res); just before the while shows this in my case:

Array
(
    [m] => 2023
    [d] => 07
    [y] => 19T13:03:01
)
@kevinoo
Copy link

kevinoo commented Apr 12, 2022

Confirmed error for the following domains:

  • France (.fr)
  • New Zeland (.nz)

I am developing a branch to solve this problem.

@maxiwheat
Copy link

@kevinoo We are still experiencing this issue, do you still plan to solve it ?

@kevinoo
Copy link

kevinoo commented Mar 14, 2023

Hi @maxiwheat
can you give me an example with this error ?

I have a solution ready, however I would like to test with more cases.

The commit is in feature/kevinoo/Fr_Nz_Handler

Thanks ❤️

@maxiwheat
Copy link

Hi @kevinoo, thanks for taking the time to look at it 🙏

We have this issue with the domain free.fr

Do you need a more complete sample of our code or only the domain is enough ?

@kevinoo
Copy link

kevinoo commented Mar 14, 2023

All I needed was the domain, thanks! 😄

I checked on the fly and I can confirm that the problem persists even with my fix, I'll try to correct it this week. 🙏

@ABouchard55
Copy link

I just pushed a fix on https://github.com/ABouchard55/phpWhois , it seemed, in this case, to be a date parsing issue that didn't consider microseconds.

@kevinoo
Copy link

kevinoo commented Mar 21, 2023

Hi @kevinoo, thanks for taking the time to look at it

Hi maxiwheat,
I publish a new version v6.0.4 with the fix for FR and NZ domain 💪

You can download from packagist: kevinoo/phpwhois

Have a nice day!

@matthiastosch
Copy link

@kevinoo thanks a lot for the fix. Helped me out!

@kevinoo kevinoo mentioned this issue Apr 12, 2023
@kevinoo
Copy link

kevinoo commented Apr 12, 2023

@e7o-de @maxiwheat @matthiastosch

Dear all,

I wanted to notify that I release the version v6.2.0 packagist: kevinoo/phpwhois.

Include a lot of improvements 😄

Improvements

Deprecation

  • Remove obsolete file "handler.template.php"
  • [Code cleanup #33] Remove deprecated "generic_parser_a_blocks" function
  • [Code cleanup #33] Deprecated "get_contact" function

@matthiastosch
Copy link

@kevinoo nice. I switched to your version 6.1. That fixed all the last issues - so I could remove my fixes in my application. Thanks again for your efforts

@e7o-de
Copy link
Author

e7o-de commented Apr 12, 2023

@kevinoo thank you very much, now I can finally get rid of my fancy workarounds with pre-parsing via RegEx and direct instantiation ;) Oh, that was ugly ...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants