From: | Thomas Hallgren <thomas(at)tada(dot)se> |
---|---|
To: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
Cc: | Kris Jurka <books(at)ejurka(dot)com>, pljava-dev(at)pgfoundry(dot)org, Alvaro Herrera <alvherre(at)commandprompt(dot)com>, pgsql-hackers(at)postgresql(dot)org |
Subject: | Re: Re: [Pljava-dev] Should creating a new base type require superuser status? |
Date: | 2008-08-03 06:11:53 |
Message-ID: | 48954C29.8010604@tada.se |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers pljava-dev |
Tom Lane wrote:
>
>> This is a non-issue in PL/Java. An integer parameter is never passed by
>> reference and there's no way the PL/Java user can get direct access to
>> backend memory.
>>
>
> So what exactly does happen when the user deliberately specifies wrong
> typlen/typbyval/typalign info when creating a type based on PL/Java
> functions?
>
>
Everything is converted into instances of Java classes such as String,
byte[], etc.
>> I think that assumption is without ground. Java doesn't permit you to
>> access memory unless you use Java classes (java.nio stuff) that is
>> explicitly designed to do that and you need native code to set such
>> things up. A PL/Java user can not do that unless he is able to link in
>> other shared objects or dll's to the backend process.
>>
>
> PL/Java itself must be doing "unsafe" things in order to interface with
> PG at all. So what your argument really is is that you have managed to
> securely sandbox the user-written code you are calling. That might or
> might not be true, but I don't think that worrying about it is without
> foundation.
>
>
I would be presumptuous to claim that I provide the sandbox. All PL/Java
does is to provide the type mapping. The sandbox as such is implicit in
Java, much in the same way that it does it for web-browsers etc.
Regardless of that, I think there's some difference in expressing a
worry that might or might not have a foundation versus claiming that
there indeed must be a security hole a mile wide ;-)
- thomas
From | Date | Subject | |
---|---|---|---|
Next Message | daveg | 2008-08-03 07:44:03 | Re: Mini improvement: statement_cost_limit |
Previous Message | Tom Lane | 2008-08-03 04:32:19 | Re: Parsing of pg_hba.conf and authentication inconsistencies |
From | Date | Subject | |
---|---|---|---|
Next Message | Daniel Tamm | 2008-08-13 19:13:39 | [Pljava-dev] How to compile 1.4.0 pljava.so from source? |
Previous Message | Tom Lane | 2008-08-02 16:12:50 | Re: Re: [Pljava-dev] Should creating a new base type require superuser status? |