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
careless use of gethostbyname() in Socket.xs #8887
Comments
From kan@dcit.czCreated by kan@dcit.czSocket::inet_aton is implemented as follows (in ext/Socket/Socket.xs): void if (!ok && (phe = gethostbyname(host))) { ST(0) = sv_newmortal(); This code fails when phe->h_length != sizeof ip_address. This can happen It is recommended to check the result gethostbyname() before using it I think the code calling gethostbyname() should be changed to read (This can leak unitialized stack bytes to "perl-land" when Perl Info
|
From @rgsThanks, I've implemented the suggested modification as change 31138. |
The RT System itself - Status changed from 'new' to 'open' |
@rgs - Status changed from 'open' to 'resolved' |
Migrated from rt.perl.org#42844 (status was 'resolved')
Searchable as RT42844$
The text was updated successfully, but these errors were encountered: