03-31-2003
EOF use
Hi,
I'd like to access a windows directory from aix with samba client.
To allow direct access (not interactive), i'm using EOF like:
smbclient \\\\winserver\\windir 'passwd' -U usersmb << EOF
cd subwindir
put myfile
EOF
The access is correct but does somebody know how to trap errors beneath EOF prompt (cd ... ? put ... ??) ?
Thank for your help.
10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
Hello, you are an awesome crowd! You answered my last questions, thank you sooo much!
I am trying to write a korn shell script that will record the memory my application is using (HP-UX B.11.11) and I have this:
if (( $APP > $THRESHOLD ))
then
echo "Warning message will display"
cat... (2 Replies)
Discussion started by: satraver
2 Replies
2. Shell Programming and Scripting
How to check for a premature EOF in a regular file in a shell/perl script?
I want to check if I have received a complete file or not.
Thanks,
Rahul. (12 Replies)
Discussion started by: rahulrathod
12 Replies
3. UNIX for Dummies Questions & Answers
hello all,
how end of a file is detected in UNIX system?
does it make use of any special symbols to identify the EOF? :(
thank you all (5 Replies)
Discussion started by: compbug
5 Replies
4. UNIX for Dummies Questions & Answers
I have written this code:
code
echo 'Now choose the file or files you want to merge your input with: \c'
read filenames
filelist=""
for file in $filenames; do
filelist="$filelist $file"
done
echo "Now that you've chosen these files ($filelist), please start typing: "
until ; do
paste -... (2 Replies)
Discussion started by: fiol73
2 Replies
5. Shell Programming and Scripting
hi,
in a shell script i came accross the following bit of code
1.shift $(($OPTIND - 1))
2.if ; then
3. cat << EOF >&2
4.Usage: $0 lockfilename
5.EOF
6. exit 1
7.fi
I am not able to understand the meaning of lines(1,3,5).
Can any one of u tell me the purpose of above said lines.... (1 Reply)
Discussion started by: ravi raj kumar
1 Replies
6. UNIX for Dummies Questions & Answers
Hello all,
I have unix file that ends with the following EOF '9999999999'
I want to remove the '\n' character after EOF. What is the command that should be included in the script, before sending the file?
will this work:
$ echo "<99999999999>\c" >> <filename>
thanks in advance. (3 Replies)
Discussion started by: priya12
3 Replies
7. Shell Programming and Scripting
I'm trying to connect to oracle with the following code in the script:
checksqlerror{
if
echo $1
exit
fi
}
$SQLPLUS username/password@schemaname
checksqlerror "failed to connect to oracle"
If I'm passing wrong schema name,instead of executing checksqlerror it stops and expects user... (2 Replies)
Discussion started by: BhawanaAggarwal
2 Replies
8. Programming
How can I write EOF into a file?
I tryed to do as follows:
size=sizeof(EOF);
end_of_file=EOF;
write(fdMutexRichieste, &end_of_file, size);
But it does non work correctly,
becouse in the next cicle (using lseek(..., SEEK_END) of my code it seems to ignore my EOF and use the LAST... (5 Replies)
Discussion started by: DNAx86
5 Replies
9. Shell Programming and Scripting
Hey!
Can I write a routine that allows me to in a txt file check line by line until the end of file?
something like
until do
---some code---
done
maybe it is a stupid question but I never learned shell scripts and I need this :p
thanks in advance (1 Reply)
Discussion started by: ruben.rodrigues
1 Replies
10. Shell Programming and Scripting
Hi friends ,
I am confused with << EOF
EOF
Most of the cases I found
sqlplus $db_conn_str << EOF
some sql staments
EOF
another exapmle is
#!/bin/sh
echo -n 'what is the value? '
read value
sed 's/XXX/'$value'/' <<EOF
The value is XXX
EOF (1 Reply)
Discussion started by: imipsita.rath
1 Replies
LEARN ABOUT PHP
krb5_auth_rules
krb5_auth_rules(5) Standards, Environments, and Macros krb5_auth_rules(5)
NAME
krb5_auth_rules - Overview of Kerberos V5 authorization
DESCRIPTION
When a user uses kerberized versions of the ftp, rdist, rcp, rlogin, rsh, or telnet clients to connect to a server, even if the user's
claimed Kerberos V5 identity is authenticated, the user is not necessarily authorized. Authentication merely proves that the user is "who
he says he is" to the Kerberos V5 authentication system. Authorization also needs to be done, since it determines if that Kerberos identity
is permitted to access the Solaris user account that the client wants to access.
Each user may have a private authorization list in a file ~/.k5login in his login directory (on the server). Each line in this file should
contain a Kerberos principal name of the form principal/instance@realm. If the server finds a ~/.k5login file, then access is granted to
the account if and only if the originating user is authenticated to one of the principals named in the ~/.k5login file.
If there is no ~/.k5login file, the originating user will then be checked against the gsscred table (see gsscred(1M)). If the originating
user's Kerberos V5 identity is in the gsscred table, and if the UNIX user id in the gsscred table corresponds to the user account the
client is trying access, then the originating user is granted access to the account on the server. If the UNIX user id does not match, then
the originating user is denied access.
For example, suppose the originating user has a principal name of jdb@ENG.ACME.COM and the target account is jdb-user. If jdb@ENG.ACME.COM
appears in the gsscred table with uid 23154 and if jdb-user appears in the user account database (see passwd(4)) with uid 23154, then
access to account jdb-user is granted. Of course, normally, the target account name in this example would be jdb and not jdb-user.
Finally, if there is no ~/.k5login file and if the originating user's Kerberos V5 identity is not in the gsscred table, then the user will
be granted access to the account if and only if all of the following are true:
o The user part of the authenticated principal name is the same as the target account name specified by the client.
o The realm part of the client and server are the same.
o The target account name exists on the server.
For example, if the originating user has a principal name of jdb@ENG.ACME.COM and if the server is in realm SALES.ACME.COM, then even if
jdb is a valid account name on the server, the client would be denied access. This is because the realms SALES.ACME.COM and ENG.ACME.COM
differ.
FILES
~/.k5login Per user-account authorization file.
/etc/passwd System account file. This information may also be in a directory service. See passwd(4).
ATTRIBUTES
See attributes(5) for a description of the following attributes:
+-----------------------------+-----------------------------+
| ATTRIBUTE TYPE | ATTRIBUTE VALUE |
+-----------------------------+-----------------------------+
|Interface Stability |Evolving |
+-----------------------------+-----------------------------+
SEE ALSO
ftp(1), rcp(1), rdist(1), rlogin(1), rsh(1), telnet(1), gsscred(1M), passwd(4), attributes(5), gss_auth_rules(5)
NOTES
To avoid security problems, the ~/.k5login file must be owned by the remote user.
SunOS 5.10 13 Apr 2004 krb5_auth_rules(5)