Search squid archive

Re: IPcache and mixed case domain names

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 12/15/21 11:56 AM, Binoy Fernandez wrote:

> Assuming the IPcache at all times contains lower case domain names
> then I think a change might be needed to the ipcache_get function to
> lower case

It sounds like you found a bug. The fix you suggest may work, but it is

* rather fragile (sooner or later we will forget to lower the name
before looking it up inside ipcache_get() or another function) and

* possibly more expensive that the alternative below (most names do not
need any case conversion but all names need hash computation).

I suspect a better fix would be to replace the legacy C hash used by the
IP cache code with a modern case-insensitive unordered set or map. At
that replacement time, the developer should investigate whether our
ClpMap should be enhanced to be reusable in this context.


Thank you,

Alex.
_______________________________________________
squid-users mailing list
squid-users@xxxxxxxxxxxxxxxxxxxxx
http://lists.squid-cache.org/listinfo/squid-users



[Index of Archives]     [Linux Audio Users]     [Samba]     [Big List of Linux Books]     [Linux USB]     [Yosemite News]

  Powered by Linux