Sponsored Content
Top Forums Shell Programming and Scripting Checking whether the entered text is file or not Post 302777503 by Rashid Khan on Friday 8th of March 2013 04:01:03 AM
Old 03-08-2013
hi busyboy...

That '$$' was a typing mistake.

thanks for the code its working fine....

Smilie Smilie
 

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

Repeat last entered command ?

Hi, how to do that ? I mean only print it but not execute. I'm using putty to interact with ksh. (in windows cmd up arrow does the job) thanks vilius (5 Replies)
Discussion started by: vilius
5 Replies

2. Shell Programming and Scripting

checking text file

Hello, I have the following report (report.txt) file (see attached). I would like to check the file and if the field is error, then showing error message at output. 1. In the report, 1st, 2st and 3nd line can be ignore to check 2. start to check line 4 (each field use "," to split - 1st... (1 Reply)
Discussion started by: happyv
1 Replies

3. UNIX for Dummies Questions & Answers

checking directory size in the text file

Hi All, I am new to unix scripting, please help me in completing this exercise, I have a scenario as follows, 1. i have a text file(snapshot.txt) consisting of directory names, and file size separated by comma as shown below: snapshot.txt data: ... (1 Reply)
Discussion started by: G.K.K
1 Replies

4. Shell Programming and Scripting

How to replace text in a file with text entered

I am trying to write a shell script that will allow the typing of a value, then using that value to replace data in a text file. I suspect I need sed. The format of the file is: Variable1:Value1 Variable2:Value2 The interaction would be something like: Shell Prompt: "Please enter the... (9 Replies)
Discussion started by: cleanden
9 Replies

5. Solaris

Question marks appearing instead of text entered

I have a netscape 4.79 browser for our GUI which connects to a Solaris5.8 box. During peek hours, we see question marks appearing in the screen instead of the text we enter. This results in query failure. This problem does not happen always, and is quite irritating because, we have to close the... (6 Replies)
Discussion started by: vanz
6 Replies

6. Shell Programming and Scripting

only a number can be entered no letters?

ok the user can only enter a number if a letter is entered it shouldnt be accepted This is what i have so far read -p "How many cars to enter:" cars until do read -p "Invalid number. Please re-enter:" $tags done (5 Replies)
Discussion started by: gangsta
5 Replies

7. Shell Programming and Scripting

How to accept command line argument as character or text if number is entered?

Hello Does the unix korn shell provide a function to convert number entered in command line argument to text or Character so that in next step i will convert Chr to Hex (6 Replies)
Discussion started by: aadityapatel198
6 Replies

8. Shell Programming and Scripting

How to check user entered correct file format or not?

Hi Experts, path=/db/files/ format=$1 User can enter any file format.compare the user file format with actual file format existed in the directory /db/files. User enter all characters as "A" apart from date format. example1: user will be entering the file format AAA_AA_YYYYMMDD.AAA Actual... (6 Replies)
Discussion started by: nalu
6 Replies

9. Shell Programming and Scripting

Checking and replacing first line in text file, one-liner?

Hello, I'm looking to check only the first line of a file to see if it is a format string, like # -*- coding: utf-8; mode: tcl; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -\*- vim:fenc=utf-8:ft=tcl:et:sw=2:ts=2:sts=2if the first line is anything else, insert the above string. I'd... (3 Replies)
Discussion started by: f77hack
3 Replies

10. Shell Programming and Scripting

Match text to lines in a file, iterate backwards until text or text substring matches, print to file

hi all, trying this using shell/bash with sed/awk/grep I have two files, one containing one column, the other containing multiple columns (comma delimited). file1.txt abc12345 def12345 ghi54321 ... file2.txt abc1,text1,texta abc,text2,textb def123,text3,textc gh,text4,textd... (6 Replies)
Discussion started by: shogun1970
6 Replies
GRID-CERT-DIAGNOST(1)						  Globus Commands					     GRID-CERT-DIAGNOST(1)

NAME
grid-cert-diagnostics - Print diagnostic information about certificates and keys SYNOPSIS
grid-cert-diagnostics [-h] | [-help] [-p] [-n] [-c CERTIFICATE] DESCRIPTION
The grid-cert-diagnostics program displays information about the current user's security environment, including information about security-related environment variables, security directory search path, personal key and certificates, and trusted certificates. It is intended to provide information to help diagnose problems using GSIC. By default, grid-cert-diagnostics prints out information regarding the environment and trusted certificate directory. If the -p command-line option is used, then additional information about the current user's default certificate and key will be printed. The full set of command-line options to grid-cert-diagnostics consists of: -h, -help Display a help message and exit. -p Display information about the personal certificate and key that is the current user's default credential. -n Check time synchronization with the ntpdate command. -c CERTIFICATE, -c - Check the validity of the certificate in the file named by CERTIFICATE or standard input if the parameter to -c is -. EXAMPLES
In this example, we see the default mode of checking the default security environment for the system, without processing the user's key and certificate. Note the user receives a warning about a cog.properties and about an expired CA certificate. % grid-cert-diagnostics Checking Environment Variables ============================== Checking if X509_CERT_DIR is set... no Checking if X509_USER_CERT is set... no Checking if X509_USER_KEY is set... no Checking if X509_USER_PROXY is set... no Checking Security Directories ======================= Determining trusted cert path... /etc/grid-security/certificates Checking for cog.properties... found WARNING: If the cog.properties file contains security properties, Java apps will ignore the security paths described in the GSI documentation Checking trusted certificates... ================================ Getting trusted certificate list... Checking CA file /etc/grid-security/certificates/1c4f4c48.0... ok Verifying certificate chain for "/etc/grid-security/certificates/1c3f2ca8.0"... ok Checking CA file /etc/grid-security/certificates/9d8788eb.0... ok Verifying certificate chain for "/etc/grid-security/certificates/9d8753eb.0"... failed globus_credential: Error verifying credential: Failed to verify credential globus_gsi_callback_module: Could not verify credential globus_gsi_callback_module: The certificate has expired: Credential with subject: /DC=org/DC=example/OU=grid/CN=CA has expired. In this example, we show a user with a mismatched private key and certificate: % grid-cert-diagnostics -p Checking Environment Variables ============================== Checking if X509_CERT_DIR is set... no Checking if X509_USER_CERT is set... no Checking if X509_USER_KEY is set... no Checking if X509_USER_PROXY is set... no Checking Security Directories ======================= Determining trusted cert path... /etc/grid-security/certificates Checking for cog.properties... not found Checking Default Credentials ============================== Determining certificate and key file names... ok Certificate Path: "/home/juser/.globus/usercert.pem" Key Path: "/home/juser/.globus/userkey.pem" Reading certificate... ok Reading private key... ok Checking Certificate Subject... "/O=Grid/OU=Example/OU=User/CN=Joe User" Checking cert... ok Checking key... ok Checking that certificate contains an RSA key... ok Checking that private key is an RSA key... ok Checking that public and private keys have the same modulus... failed Private key modulus: D294849E37F048C3B5ACEEF2CCDF97D88B679C361E29D5CB5 219C3E948F3E530CFC609489759E1D751F0ACFF0515A614276A0F4C11A57D92D7165B8 FA64E3140155DE448D45C182F4657DA13EDA288423F5B9D169DFF3822EFD81EB2E6403 CE3CB4CCF96B65284D92592BB1673A18354DA241B9AFD7F494E54F63A93E15DCAE2 Public key modulus : C002C7B329B13BFA87BAF214EACE3DC3D490165ACEB791790 600708C544175D9193C9BAC5AED03B7CB49BB6AE6D29B7E635FAC751E9A6D1CEA98022 6F1B63002902D6623A319E4682E7BFB0968DCE962CF218AAD95FAAD6A0BA5C42AA9AAF 7FDD32B37C6E2B2FF0E311310AA55FFB9EAFDF5B995C7D9EEAD8D5D81F3531E0AE5 Certificate and and private key don't match AUTHOR
University of Chicago Globus Toolkit 5.0.2 04/25/2011 GRID-CERT-DIAGNOST(1)
All times are GMT -4. The time now is 03:15 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy