Re: [webkit-dev] Changing the implementation of KURL
On Fri, Jan 27, 2012 at 9:44 PM, Darin Fisher da...@chromium.org wrote: On Fri, Jan 27, 2012 at 2:39 AM, Adam Barth aba...@webkit.org wrote: On Fri, Jan 27, 2012 at 1:49 AM, Maciej Stachowiak m...@apple.com wrote: That said, this plan was based on the premise that Chromium folks were willing to cooperate with the unforking effort, and would be happy to use a WebKit-integrated URL library based on GoogleURL. If that is no longer the case, then certainly we should not proceed on a false premise. I've been talking a bit with Benjamin about this topic off-list. I'm hopeful that with some careful attention to dependencies and interfaces, Chromium will be able to use WTFURL in place of GoogleURL. I still think it is a bit backwards for Chromium's network stack to depend on WebKit, but I remain open minded about this. I'm curious how it will work out. The general approach I had in mind was to view WTFURL as a separate library that just happens to be hosted at svn.webkit.org. That requires some careful managing of dependencies but it seems worth trying. Adam ___ webkit-dev mailing list webkit-dev@lists.webkit.org http://lists.webkit.org/mailman/listinfo.cgi/webkit-dev
Re: [webkit-dev] Changing the implementation of KURL
-Original Message- From: webkit-dev-boun...@lists.webkit.org [mailto:webkit-dev- boun...@lists.webkit.org] On Behalf Of Adam Barth Sent: Saturday, January 28, 2012 3:20 AM To: Darin Fisher Cc: Benjamin Poulain; WebKit Development Subject: Re: [webkit-dev] Changing the implementation of KURL The general approach I had in mind was to view WTFURL as a separate library that just happens to be hosted at svn.webkit.org. That requires some careful managing of dependencies but it seems worth trying. It would be handy if WTF as a whole could be used as a platform utility library. WTF::String in particular to stop string classes from multiplying: if the platform's network stack return headers as C strings, and you want to do some munging before passing them to WebKit, you can avoid data copies by converting them to WTF::String as soon as possible, rather than converting from C strings to (say) std::string and then again to WTF::String on entering webkit. While we're talking about hosting utility libraries that only some ports would use, it would be REALLY handy to have One True Cookie Parser, since right now WebKit leaves it to the network stack, and there are so many stacks that have substandard or non-existant cookie parsers that need to be reimplemented. Joe - This transmission (including any attachments) may contain confidential information, privileged material (including material protected by the solicitor-client or other applicable privileges), or constitute non-public information. Any use of this information by anyone other than the intended recipient is prohibited. If you have received this transmission in error, please immediately reply to the sender and delete this information from your system. Use, dissemination, distribution, or reproduction of this transmission by unintended recipients is not authorized and may be unlawful. ___ webkit-dev mailing list webkit-dev@lists.webkit.org http://lists.webkit.org/mailman/listinfo.cgi/webkit-dev
Re: [webkit-dev] Changing the implementation of KURL
On Sat, Jan 28, 2012 at 12:19 AM, Adam Barth aba...@webkit.org wrote: On Fri, Jan 27, 2012 at 9:44 PM, Darin Fisher da...@chromium.org wrote: On Fri, Jan 27, 2012 at 2:39 AM, Adam Barth aba...@webkit.org wrote: On Fri, Jan 27, 2012 at 1:49 AM, Maciej Stachowiak m...@apple.com wrote: That said, this plan was based on the premise that Chromium folks were willing to cooperate with the unforking effort, and would be happy to use a WebKit-integrated URL library based on GoogleURL. If that is no longer the case, then certainly we should not proceed on a false premise. I've been talking a bit with Benjamin about this topic off-list. I'm hopeful that with some careful attention to dependencies and interfaces, Chromium will be able to use WTFURL in place of GoogleURL. I still think it is a bit backwards for Chromium's network stack to depend on WebKit, but I remain open minded about this. I'm curious how it will work out. The general approach I had in mind was to view WTFURL as a separate library that just happens to be hosted at svn.webkit.org. That requires some careful managing of dependencies but it seems worth trying. I don't really want to reopen this debate, but how is that different than checking GoogleURL into webkit? Maciej was saying that this would impose an unacceptable burden on WebKit developers. I'm wondering what his specific complaints about burden are and whether they might also apply to a standalone WTFURL class. For example, if Maciej is concerned about coding style, we can easily fix that either way and it's a non-issue. If the concern is familiarity, I'm not sure I see the difference between Adam reimplementing WTFURL and using some existing code since they're both new code from the perspective of average WebKit contributors. I'm asking because I suspect Maciej's main concern is control over the library and dependencies and the ability to easily make changes necessary for Apple and WebKit (I would be worried about this, too). From my perspective, however, this might imply that he would want the ability in the future to make modifications and add dependencies that would be nonstarters with respect to Chromium's requirements. The normal answer (which I agree with) when some random port wants to do something weird and be able to compile without, for example, JavaScript, is that WebKit doesn't support these one-off use cases, take the whole thing and we should agree that this reasoning wouldn't apply to dependencies on the URL component. I think there was some agreement last year when the first part of this project happened. If we restart it, I would want to again make sure that everybody really understands what our dependency requirements are and agree that we're not going to be changing them because it's better for the WebKit community (c.f. Joe Mason's request to use all of WTF). I also worry that this will be a 9 month project for Adam, as the current partially done parsing thing took longer than anybody would have liked. Personally I would prefer Adam spend time fixing my security bugs :) So I want to be explicit on what Apple perceives as the benefit of Adam writes a bunch of new well-tested code with no dependencies vs. copy existing well-tested code with no dependencies into third_party and possibly reformat so we can make sure there are no surprises later. That said, I am quite supportive of you unification work for the benefit of WebKit! Brett ___ webkit-dev mailing list webkit-dev@lists.webkit.org http://lists.webkit.org/mailman/listinfo.cgi/webkit-dev
Re: [webkit-dev] Changing the implementation of KURL
On Jan 28, 2012, at 9:24 AM, Brett Wilson wrote: On Sat, Jan 28, 2012 at 12:19 AM, Adam Barth aba...@webkit.org wrote: On Fri, Jan 27, 2012 at 9:44 PM, Darin Fisher da...@chromium.org wrote: On Fri, Jan 27, 2012 at 2:39 AM, Adam Barth aba...@webkit.org wrote: On Fri, Jan 27, 2012 at 1:49 AM, Maciej Stachowiak m...@apple.com wrote: That said, this plan was based on the premise that Chromium folks were willing to cooperate with the unforking effort, and would be happy to use a WebKit-integrated URL library based on GoogleURL. If that is no longer the case, then certainly we should not proceed on a false premise. I've been talking a bit with Benjamin about this topic off-list. I'm hopeful that with some careful attention to dependencies and interfaces, Chromium will be able to use WTFURL in place of GoogleURL. I still think it is a bit backwards for Chromium's network stack to depend on WebKit, but I remain open minded about this. I'm curious how it will work out. The general approach I had in mind was to view WTFURL as a separate library that just happens to be hosted at svn.webkit.org. That requires some careful managing of dependencies but it seems worth trying. I don't really want to reopen this debate, but how is that different than checking GoogleURL into webkit? Maciej was saying that this would impose an unacceptable burden on WebKit developers. I'm wondering what his specific complaints about burden are and whether they might also apply to a standalone WTFURL class. For example, if Maciej is concerned about coding style, we can easily fix that either way and it's a non-issue. If the concern is familiarity, I'm not sure I see the difference between Adam reimplementing WTFURL and using some existing code since they're both new code from the perspective of average WebKit contributors. I don't think anyone is expecting to implement new URL code from scratch. The proposals that were put forward are, as I understand them: (1) Check in GoogleURL as-is into the ThirdParty directory as an external dependency; future maintenance would be done via the canonical GoogleURL repository. (2) Check in GoogleURL as a proper part of WebKit, adapting its coding style and wrapping it in a way that works well with other WebKit/WTF data types. The issue is not new code or not, but the ability to maintain it going forward. I'm asking because I suspect Maciej's main concern is control over the library and dependencies and the ability to easily make changes necessary for Apple and WebKit (I would be worried about this, too). That's exactly it. From my perspective, however, this might imply that he would want the ability in the future to make modifications and add dependencies that would be nonstarters with respect to Chromium's requirements. The normal answer (which I agree with) when some random port wants to do something weird and be able to compile without, for example, JavaScript, is that WebKit doesn't support these one-off use cases, take the whole thing and we should agree that this reasoning wouldn't apply to dependencies on the URL component. I think there was some agreement last year when the first part of this project happened. If we restart it, I would want to again make sure that everybody really understands what our dependency requirements are and agree that we're not going to be changing them because it's better for the WebKit community (c.f. Joe Mason's request to use all of WTF). I also worry that this will be a 9 month project for Adam, as the current partially done parsing thing took longer than anybody would have liked. Personally I would prefer Adam spend time fixing my security bugs :) So I want to be explicit on what Apple perceives as the benefit of Adam writes a bunch of new well-tested code with no dependencies vs. copy existing well-tested code with no dependencies into third_party and possibly reformat so we can make sure there are no surprises later. I think that, at this point, Benjamin is volunteering to do the bulk of work and Adam is offering to help. The code would be more along the lines of reformatting and refactoring than write[ing] a bunch of new code as I understand it. I understand your concern about wanting to keept his code free of unwanted dependencies. However, we do already have a pretty hard boundary that WTF can't depend on anything higher in the stack. We could make WTFURL even more restricted if that was necessary or helpful. However, I think most of us who do not work on Chromium are not clear on what exactly the dependency constraints are. It would be helpful if you or Adam or someone else could document them. Let's take some specific examples. Would using WTF::Vector inside the implementation (not necessarily at the API boundary, just internally) be acceptable? Or would it be required to use C arrays or std::vector? Would using WTF's ASSERT family of macros be acceptable, or
Re: [webkit-dev] Changing the implementation of KURL
On Sat, Jan 28, 2012 at 4:07 PM, Maciej Stachowiak m...@apple.com wrote: On Jan 28, 2012, at 9:24 AM, Brett Wilson wrote: On Sat, Jan 28, 2012 at 12:19 AM, Adam Barth aba...@webkit.org wrote: On Fri, Jan 27, 2012 at 9:44 PM, Darin Fisher da...@chromium.org wrote: On Fri, Jan 27, 2012 at 2:39 AM, Adam Barth aba...@webkit.org wrote: On Fri, Jan 27, 2012 at 1:49 AM, Maciej Stachowiak m...@apple.com wrote: That said, this plan was based on the premise that Chromium folks were willing to cooperate with the unforking effort, and would be happy to use a WebKit-integrated URL library based on GoogleURL. If that is no longer the case, then certainly we should not proceed on a false premise. I've been talking a bit with Benjamin about this topic off-list. I'm hopeful that with some careful attention to dependencies and interfaces, Chromium will be able to use WTFURL in place of GoogleURL. I still think it is a bit backwards for Chromium's network stack to depend on WebKit, but I remain open minded about this. I'm curious how it will work out. The general approach I had in mind was to view WTFURL as a separate library that just happens to be hosted at svn.webkit.org. That requires some careful managing of dependencies but it seems worth trying. I don't really want to reopen this debate, but how is that different than checking GoogleURL into webkit? Maciej was saying that this would impose an unacceptable burden on WebKit developers. I'm wondering what his specific complaints about burden are and whether they might also apply to a standalone WTFURL class. For example, if Maciej is concerned about coding style, we can easily fix that either way and it's a non-issue. If the concern is familiarity, I'm not sure I see the difference between Adam reimplementing WTFURL and using some existing code since they're both new code from the perspective of average WebKit contributors. I don't think anyone is expecting to implement new URL code from scratch. The proposals that were put forward are, as I understand them: (1) Check in GoogleURL as-is into the ThirdParty directory as an external dependency; future maintenance would be done via the canonical GoogleURL repository. (2) Check in GoogleURL as a proper part of WebKit, adapting its coding style and wrapping it in a way that works well with other WebKit/WTF data types. The issue is not new code or not, but the ability to maintain it going forward. That's great, thanks. I'm asking because I suspect Maciej's main concern is control over the library and dependencies and the ability to easily make changes necessary for Apple and WebKit (I would be worried about this, too). That's exactly it. From my perspective, however, this might imply that he would want the ability in the future to make modifications and add dependencies that would be nonstarters with respect to Chromium's requirements. The normal answer (which I agree with) when some random port wants to do something weird and be able to compile without, for example, JavaScript, is that WebKit doesn't support these one-off use cases, take the whole thing and we should agree that this reasoning wouldn't apply to dependencies on the URL component. I think there was some agreement last year when the first part of this project happened. If we restart it, I would want to again make sure that everybody really understands what our dependency requirements are and agree that we're not going to be changing them because it's better for the WebKit community (c.f. Joe Mason's request to use all of WTF). I also worry that this will be a 9 month project for Adam, as the current partially done parsing thing took longer than anybody would have liked. Personally I would prefer Adam spend time fixing my security bugs :) So I want to be explicit on what Apple perceives as the benefit of Adam writes a bunch of new well-tested code with no dependencies vs. copy existing well-tested code with no dependencies into third_party and possibly reformat so we can make sure there are no surprises later. I think that, at this point, Benjamin is volunteering to do the bulk of work and Adam is offering to help. The code would be more along the lines of reformatting and refactoring than write[ing] a bunch of new code as I understand it. I understand your concern about wanting to keept his code free of unwanted dependencies. However, we do already have a pretty hard boundary that WTF can't depend on anything higher in the stack. We could make WTFURL even more restricted if that was necessary or helpful. However, I think most of us who do not work on Chromium are not clear on what exactly the dependency constraints are. It would be helpful if you or Adam or someone else could document them. Let's take some specific examples. Would using WTF::Vector inside the implementation (not necessarily at the API boundary, just internally) be acceptable? Or
Re: [webkit-dev] Changing the implementation of KURL
On Sat, Jan 28, 2012 at 4:48 PM, Brett Wilson bre...@chromium.org wrote: On Sat, Jan 28, 2012 at 4:07 PM, Maciej Stachowiak m...@apple.com wrote: On Jan 28, 2012, at 9:24 AM, Brett Wilson wrote: On Sat, Jan 28, 2012 at 12:19 AM, Adam Barth aba...@webkit.org wrote: On Fri, Jan 27, 2012 at 9:44 PM, Darin Fisher da...@chromium.org wrote: On Fri, Jan 27, 2012 at 2:39 AM, Adam Barth aba...@webkit.org wrote: On Fri, Jan 27, 2012 at 1:49 AM, Maciej Stachowiak m...@apple.com wrote: That said, this plan was based on the premise that Chromium folks were willing to cooperate with the unforking effort, and would be happy to use a WebKit-integrated URL library based on GoogleURL. If that is no longer the case, then certainly we should not proceed on a false premise. I've been talking a bit with Benjamin about this topic off-list. I'm hopeful that with some careful attention to dependencies and interfaces, Chromium will be able to use WTFURL in place of GoogleURL. I still think it is a bit backwards for Chromium's network stack to depend on WebKit, but I remain open minded about this. I'm curious how it will work out. The general approach I had in mind was to view WTFURL as a separate library that just happens to be hosted at svn.webkit.org. That requires some careful managing of dependencies but it seems worth trying. I don't really want to reopen this debate, but how is that different than checking GoogleURL into webkit? Maciej was saying that this would impose an unacceptable burden on WebKit developers. I'm wondering what his specific complaints about burden are and whether they might also apply to a standalone WTFURL class. For example, if Maciej is concerned about coding style, we can easily fix that either way and it's a non-issue. If the concern is familiarity, I'm not sure I see the difference between Adam reimplementing WTFURL and using some existing code since they're both new code from the perspective of average WebKit contributors. I don't think anyone is expecting to implement new URL code from scratch. The proposals that were put forward are, as I understand them: (1) Check in GoogleURL as-is into the ThirdParty directory as an external dependency; future maintenance would be done via the canonical GoogleURL repository. (2) Check in GoogleURL as a proper part of WebKit, adapting its coding style and wrapping it in a way that works well with other WebKit/WTF data types. The issue is not new code or not, but the ability to maintain it going forward. That's great, thanks. I'm asking because I suspect Maciej's main concern is control over the library and dependencies and the ability to easily make changes necessary for Apple and WebKit (I would be worried about this, too). That's exactly it. From my perspective, however, this might imply that he would want the ability in the future to make modifications and add dependencies that would be nonstarters with respect to Chromium's requirements. The normal answer (which I agree with) when some random port wants to do something weird and be able to compile without, for example, JavaScript, is that WebKit doesn't support these one-off use cases, take the whole thing and we should agree that this reasoning wouldn't apply to dependencies on the URL component. I think there was some agreement last year when the first part of this project happened. If we restart it, I would want to again make sure that everybody really understands what our dependency requirements are and agree that we're not going to be changing them because it's better for the WebKit community (c.f. Joe Mason's request to use all of WTF). I also worry that this will be a 9 month project for Adam, as the current partially done parsing thing took longer than anybody would have liked. Personally I would prefer Adam spend time fixing my security bugs :) So I want to be explicit on what Apple perceives as the benefit of Adam writes a bunch of new well-tested code with no dependencies vs. copy existing well-tested code with no dependencies into third_party and possibly reformat so we can make sure there are no surprises later. I think that, at this point, Benjamin is volunteering to do the bulk of work and Adam is offering to help. The code would be more along the lines of reformatting and refactoring than write[ing] a bunch of new code as I understand it. I understand your concern about wanting to keept his code free of unwanted dependencies. However, we do already have a pretty hard boundary that WTF can't depend on anything higher in the stack. We could make WTFURL even more restricted if that was necessary or helpful. However, I think most of us who do not work on Chromium are not clear on what exactly the dependency constraints are. It would be helpful if you or Adam or someone else could document them. Let's take some specific examples. Would using WTF::Vector inside the implementation
Re: [webkit-dev] Changing the implementation of KURL
-Original Message- From: webkit-dev-boun...@lists.webkit.org [mailto:webkit-dev- boun...@lists.webkit.org] On Behalf Of Maciej Stachowiak Sent: Saturday, January 28, 2012 7:08 PM To: Brett Wilson Cc: Benjamin Poulain; WebKit Development Subject: Re: [webkit-dev] Changing the implementation of KURL Let's take some specific examples. Would using WTF::Vector inside the implementation (not necessarily at the API boundary, just internally) be acceptable? Or would it be required to use C arrays or std::vector? Would using WTF's ASSERT family of macros be acceptable, or should some other form of asserts be used? The are examples I can think of where dependencies could simply be added in the course of trying to get the code to be in WebKit style. Another big potential dependency would be use of Platform.h and the ENABLE/USE/etc system of macros - I could easily see a new feature including special processing for a new URL scheme, similar to the way file: url's have slightly different parsing rules than http: urls. In this case we'd want to wrap the special handling in ENABLE(feature). (Arguably the url class should be flexible enough that you don't have to hardcode special handling for a scheme, though.) Joe - This transmission (including any attachments) may contain confidential information, privileged material (including material protected by the solicitor-client or other applicable privileges), or constitute non-public information. Any use of this information by anyone other than the intended recipient is prohibited. If you have received this transmission in error, please immediately reply to the sender and delete this information from your system. Use, dissemination, distribution, or reproduction of this transmission by unintended recipients is not authorized and may be unlawful. ___ webkit-dev mailing list webkit-dev@lists.webkit.org http://lists.webkit.org/mailman/listinfo.cgi/webkit-dev
Re: [webkit-dev] Changing the implementation of KURL
On Sat, Jan 28, 2012 at 5:28 PM, Joe Mason jma...@rim.com wrote: -Original Message- From: webkit-dev-boun...@lists.webkit.org [mailto:webkit-dev- boun...@lists.webkit.org] On Behalf Of Maciej Stachowiak Sent: Saturday, January 28, 2012 7:08 PM To: Brett Wilson Cc: Benjamin Poulain; WebKit Development Subject: Re: [webkit-dev] Changing the implementation of KURL Let's take some specific examples. Would using WTF::Vector inside the implementation (not necessarily at the API boundary, just internally) be acceptable? Or would it be required to use C arrays or std::vector? Would using WTF's ASSERT family of macros be acceptable, or should some other form of asserts be used? The are examples I can think of where dependencies could simply be added in the course of trying to get the code to be in WebKit style. Another big potential dependency would be use of Platform.h and the ENABLE/USE/etc system of macros - I could easily see a new feature including special processing for a new URL scheme, similar to the way file: url's have slightly different parsing rules than http: urls. In this case we'd want to wrap the special handling in ENABLE(feature). (Arguably the url class should be flexible enough that you don't have to hardcode special handling for a scheme, though.) I don't see that as being much of an issue. Google Safe Browsing can always write their own Platform.h that does what they need. Brett ___ webkit-dev mailing list webkit-dev@lists.webkit.org http://lists.webkit.org/mailman/listinfo.cgi/webkit-dev
Re: [webkit-dev] Changing the implementation of KURL
On Sat, Jan 28, 2012 at 4:59 PM, Brett Wilson bre...@chromium.org wrote: So to clarify, I think we need to keep the current architecture. Obviously WebKit needs a URL class that uses its String class, so WTFURL would probably be a wrapper around some core library for WebKit to use. Chromium would rewrite our GURL class to use the same core library and keep std::strings (we don't want all our browser-level code to have to convert std::string - WTF::String just like today we don't want to do the inverse in WebKit). I don't really get this point. With WTF linked statically, no matter how largish WTF, it will not cost much to use. You say you don't want to convert std::string-WTF::String and WTF::String at the browser level, but aren't you doing that a lot more with the current code? Parsing valid URL can probably be done without WTF. URL canonicalization is frequent in WebKit and I would think using String directly is a good idea. Same for modifying a URL. Chromium is the only ports that use the same URL Class in the whole stack. And it seems you do not want any dependencies on WTF. Maybe an alternative is to change this and convert KURL-GoogleURL on platform boundaries like the other ports? Benjamin ___ webkit-dev mailing list webkit-dev@lists.webkit.org http://lists.webkit.org/mailman/listinfo.cgi/webkit-dev
Re: [webkit-dev] Changing the implementation of KURL
The other concern I have is about the stability of the API to the URL guts that GURL living in the chromium repository would depend on. Anyone changing the URL guts would need to be careful not to break that contract. This seems like it might be annoying for those who do not work on chromium. On Jan 28, 2012 5:43 PM, Brett Wilson bre...@chromium.org wrote: On Sat, Jan 28, 2012 at 5:28 PM, Joe Mason jma...@rim.com wrote: -Original Message- From: webkit-dev-boun...@lists.webkit.org [mailto:webkit-dev- boun...@lists.webkit.org] On Behalf Of Maciej Stachowiak Sent: Saturday, January 28, 2012 7:08 PM To: Brett Wilson Cc: Benjamin Poulain; WebKit Development Subject: Re: [webkit-dev] Changing the implementation of KURL Let's take some specific examples. Would using WTF::Vector inside the implementation (not necessarily at the API boundary, just internally) be acceptable? Or would it be required to use C arrays or std::vector? Would using WTF's ASSERT family of macros be acceptable, or should some other form of asserts be used? The are examples I can think of where dependencies could simply be added in the course of trying to get the code to be in WebKit style. Another big potential dependency would be use of Platform.h and the ENABLE/USE/etc system of macros - I could easily see a new feature including special processing for a new URL scheme, similar to the way file: url's have slightly different parsing rules than http: urls. In this case we'd want to wrap the special handling in ENABLE(feature). (Arguably the url class should be flexible enough that you don't have to hardcode special handling for a scheme, though.) I don't see that as being much of an issue. Google Safe Browsing can always write their own Platform.h that does what they need. Brett ___ webkit-dev mailing list webkit-dev@lists.webkit.org http://lists.webkit.org/mailman/listinfo.cgi/webkit-dev ___ webkit-dev mailing list webkit-dev@lists.webkit.org http://lists.webkit.org/mailman/listinfo.cgi/webkit-dev
Re: [webkit-dev] Changing the implementation of KURL
On Sat, Jan 28, 2012 at 5:51 PM, Benjamin Poulain benja...@webkit.org wrote: On Sat, Jan 28, 2012 at 4:59 PM, Brett Wilson bre...@chromium.org wrote: So to clarify, I think we need to keep the current architecture. Obviously WebKit needs a URL class that uses its String class, so WTFURL would probably be a wrapper around some core library for WebKit to use. Chromium would rewrite our GURL class to use the same core library and keep std::strings (we don't want all our browser-level code to have to convert std::string - WTF::String just like today we don't want to do the inverse in WebKit). I don't really get this point. With WTF linked statically, no matter how largish WTF, it will not cost much to use. You say you don't want to convert std::string-WTF::String and WTF::String at the browser level, but aren't you doing that a lot more with the current code? Parsing valid URL can probably be done without WTF. URL canonicalization is frequent in WebKit and I would think using String directly is a good idea. Same for modifying a URL. GURL abstracts the underlying storage so that the canonicalized URL is written directly into the proper type. As far as I can tell, there isn't much advantage to WTFURL committing to a particular string type. Chromium is the only ports that use the same URL Class in the whole stack. And it seems you do not want any dependencies on WTF. Maybe an alternative is to change this and convert KURL-GoogleURL on platform boundaries like the other ports? My guess is you won't be able to convince fishd to use different URL libraries at different layers in Chromium. There's a long history of that causing security vulnerabilities, both in Firefox and in Safari. Adam ___ webkit-dev mailing list webkit-dev@lists.webkit.org http://lists.webkit.org/mailman/listinfo.cgi/webkit-dev
Re: [webkit-dev] Changing the implementation of KURL
On Sat, Jan 28, 2012 at 6:01 PM, Adam Barth aba...@webkit.org wrote: On Sat, Jan 28, 2012 at 5:51 PM, Benjamin Poulain benja...@webkit.org wrote: On Sat, Jan 28, 2012 at 4:59 PM, Brett Wilson bre...@chromium.org wrote: So to clarify, I think we need to keep the current architecture. Obviously WebKit needs a URL class that uses its String class, so WTFURL would probably be a wrapper around some core library for WebKit to use. Chromium would rewrite our GURL class to use the same core library and keep std::strings (we don't want all our browser-level code to have to convert std::string - WTF::String just like today we don't want to do the inverse in WebKit). I don't really get this point. With WTF linked statically, no matter how largish WTF, it will not cost much to use. You say you don't want to convert std::string-WTF::String and WTF::String at the browser level, but aren't you doing that a lot more with the current code? Parsing valid URL can probably be done without WTF. URL canonicalization is frequent in WebKit and I would think using String directly is a good idea. Same for modifying a URL. GURL abstracts the underlying storage so that the canonicalized URL is written directly into the proper type. As far as I can tell, there isn't much advantage to WTFURL committing to a particular string type. Chromium is the only ports that use the same URL Class in the whole stack. And it seems you do not want any dependencies on WTF. Maybe an alternative is to change this and convert KURL-GoogleURL on platform boundaries like the other ports? My guess is you won't be able to convince fishd to use different URL libraries at different layers in Chromium. There's a long history of that causing security vulnerabilities, both in Firefox and in Safari. Right. In Firefox, the problem was that the cookie code used some hand-rolled string parsing code instead of reusing the URL parsing code. That resulted in a subtle bug that could be exploited to steal cookies. In Safari's case, I believe it was caused by differences between CFNetwork and KURL. If CFNetwork exposed an API to its URL parser, then it would be super wise for any port of WebKit using CFNetwork to reuse the same URL parser. -Darin ___ webkit-dev mailing list webkit-dev@lists.webkit.org http://lists.webkit.org/mailman/listinfo.cgi/webkit-dev
Re: [webkit-dev] Changing the implementation of KURL
On Sat, Jan 28, 2012 at 8:01 PM, Darin Fisher da...@chromium.org wrote: If CFNetwork exposed an API to its URL parser, then it would be super wise for any port of WebKit using CFNetwork to reuse the same URL parser. That is an interesting idea. I always considered it would be beneficial to have a single implementation in order to have a consistent behavior and the same security/bug fixes. You have a good point, maybe it is in the interest of the ports to split KURL... Benjamin ___ webkit-dev mailing list webkit-dev@lists.webkit.org http://lists.webkit.org/mailman/listinfo.cgi/webkit-dev