Operating System - HP-UX
1819696 Members
3389 Online
109605 Solutions
New Discussion юеВ

pgp: Execute permission denied.

 
SOLVED
Go to solution
Manuales
Super Advisor

pgp: Execute permission denied.

Hi ...
i create the following
/home/user1/.pgp folder (owner user1)
under .pgp folder are located the files:
-rw-r--r-- 1 root sys 576 Aug 18 2004 EBusSvr.lic
-rw------- 1 user1 sapsys2 146 Sep 22 18:24 PGPgroup.pgr
-rw------- 1 user1 sapsys2 1297 Aug 18 2004 hrpublic.asc
-rwxr-xr-x 1 user1 sapsys2 27450 Aug 18 2004 pgp.cfg
-rwxrwxr-x 1 user1 sapsys2 23453 Sep 25 05:55 pubring.pkr
-rw------- 1 user1 sapsys2 512 Sep 25 16:22 randseed.rnd
-rw------- 1 user1 sapsys2 975 Sep 25 05:55 secring.skr

could you please let me know why is appearing the message:
pgp: Execute permission denied.

it has been the same for other user where it is running well from cron with no problems.

this message of error appears in the log on unix when the script for cryting the information is running from SAP ...

could you please let me know what file hava a wrong permission?

6 REPLIES 6
Steven E. Protter
Exalted Contributor
Solution

Re: pgp: Execute permission denied.

Shalom,

normally this message occurs when a binary file is not executable. I see no reason for keyring files to be executable, but check the actual binaries first.

SEP
Steven E Protter
Owner of ISN Corporation
http://isnamerica.com
http://hpuxconsulting.com
Sponsor: http://hpux.ws
Twitter: http://twitter.com/hpuxlinux
Founder http://newdatacloud.com
Steven Schweda
Honored Contributor

Re: pgp: Execute permission denied.

> pgp: Execute permission denied.

Is that the whole message, or is it more
like this one:

sh: pgp: Execute permission denied.

?


> [...] what file hava a wrong permission?

Which "pgp" are you trying to run? PATH = ?
"type pgp" or "which pgp" (or whatever your
shell uses)?
AwadheshPandey
Honored Contributor

Re: pgp: Execute permission denied.

it has been the same for other user where it is running well from cron with no problems

means root's cron or any users cron, if it is runing from roots cron, then u need to check permission as well as if user have rights to run the command, some command does not allow to execute by normal users.
It's kind of fun to do the impossible
Steve Post
Trusted Contributor

Re: pgp: Execute permission denied.

1. Is user "user1" really running pgp?

2. Did you check the permissions of the directory where the encrypted file would go to?
And that parent's directory.
And the one above that.
And the next one above that.
I could say it an easier way....
If you are making file /a/b/c/d/e/f/g/file.
You see to see is user1 can get into:
/a
and
/a/b
and
/a/b/c
and ....... all the way to /a/b/c/d/e/f/g.
And you need to make sure user1 can write to /a/b/c/d/e/f/g.

3. I'm just thinking that MAYBE pgp is fine. MAYBE it just happens to be the last command that had an error. If it said "cat: permission denied." I bet you would not be looking for how to use "cat". Right?
Wait....
Why don't you try that. Replace the pgp command with a simple cat command. I know the output file will be wrong. But you are trying to find the problem. If you still have the error, then you would know that PGP is not the cause.

Manuales
Super Advisor

Re: pgp: Execute permission denied.

thanks a lot for your advises ....

i want to tell you one more thing ..
i want to be more clear how we are trying to use pgp:

there is a script "test" which contains several commands and one of them is pgp for crypting a file. this test file lives in patito2 server

server1= patito1
user of server1 = user1 (.rhosts enabled)

server2= patito2
user of server2 = user1 (.rhosts enabled)

user1 user from patito1 server wants to run the test file located into patito2 server

when i run the script over operating system loged as user1 in patito2 it works ... with no problem , in fact the test file lives there.

when i run the script from patito1 through remsh works:
remsh patito2.mydomain.com /scripts/test also works.
pgp command works well

but, when user1 run the script through SAP only works some commands (cat, ls, etc),when the script is run through a job and when gets to pgp command is when the error appears: pgp: Execute permission denied.
into a log on unix and SAP log only shows:


27.09.2007 16:09:46 Job started
27.09.2007 16:09:46 Step 001 started
27.09.2007 16:09:46 External program: /scripts/test
27.09.2007 16:09:46 Related parameter:
27.09.2007 16:09:53 Ext. prog.: SAPXPG started on patito1_PAT_22, Process ID 3786, Process Number 14
27.09.2007 16:09:53 Job finished

what could be the problem?
could be that pgp is not intalled into patito1 server?

please let me know more options please ...
thanks.
Dennis Handly
Acclaimed Contributor

Re: pgp: Execute permission denied.

>when user1 run the script through SAP only works some commands (cat, ls, etc),when the script is run through a job and when gets to pgp command is when the error appears: pgp: Execute permission denied.

You need to give an absolute path or you must figure out which pgp you are trying to execute.
When you use remsh, you don't execute your .profile.

As mentioned before by Steven, you should use whence pgp to see what pgp the shell wants.