pg.ddx.io  pgsql-admin@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Mladen Gogala <gogala.mladen@gmail.com>
To: pgsql-admin@lists.postgresql.org
Subject: Re: Hide function source
Date: Sun, 10 Oct 2021 10:08:02 -0400
Message-ID: <77700cbc-99da-c231-1234-b207494b49a9@gmail.com> (raw)
In-Reply-To: <1331401808.1491628.1633855833151@mail.yahoo.com>
References: <1331401808.1491628.1633855833151.ref@mail.yahoo.com>
	<1331401808.1491628.1633855833151@mail.yahoo.com>


On 10/10/21 04:50, Nelson Gonzaga wrote:
> Dear,
> How do I hide a function source code from all users except superuser, 
> but all can execute it?
> Thanks,
> Nelson

That is not possible. Postgres doesn't store functions in the compiled 
form, it stores them in the source form. Each process that executes a 
function has to compile it first. If you are looking for something like 
the Oracle "wrap", it might exist as an extension, I don't know. Please 
be aware that even Oracle "wrap" is not very secure. There is a public 
SQL*Developer extension which unwraps the wrapped source code.

-- 
Mladen Gogala
Database Consultant
Tel: (347) 321-1217
https://dbwhisperer.wordpress.com

view thread (4+ messages)  latest in thread

Message-ID: <77700cbc-99da-c231-1234-b207494b49a9@gmail.com>
Permalink:  ../77700cbc-99da-c231-1234-b207494b49a9@gmail.com/
Also on:    postgresql.org/message-id/77700cbc-99da-c231-1234-b207494b49a9@gmail.com

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: pgsql-admin@postgresql.org
  Cc: gogala.mladen@gmail.com, pgsql-admin@lists.postgresql.org
  Subject: Re: Hide function source
  In-Reply-To: <77700cbc-99da-c231-1234-b207494b49a9@gmail.com>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox