Sponsored Content
Full Discussion: Anyone like a challenge?
Top Forums Shell Programming and Scripting Anyone like a challenge? Post 302934903 by BatterBits on Wednesday 11th of February 2015 09:19:57 PM
Old 02-11-2015
Don,

Don't want to take too much of your time - given that I have a result - however, to answer your points:

I copied & executed your code exactly from your reply - and pasted the output. As far as I know, there are no hidden characters, no minus signs and nothing added.

Interestingly, if I execute the bracketed ls statement, I get this:

Code:
>ls *.log.0??|tail -n 6
h20150126.log.001   h20150129.log.001   h20150201.log.001   h20150204.log.001   h20150207.log.001   h20150210.log.001   h20150211.log.003
h20150127.log.001   h20150130.log.001   h20150202.log.001   h20150205.log.001   h20150208.log.001   h20150211.log.001   h20150212.log.001
h20150128.log.001   h20150131.log.001   h20150203.log.001   h20150206.log.001   h20150209.log.001   h20150211.log.002   h20150212.log.002

this lists them top to bottom, left to right
###
looking at the output from the whole command, it is presenting the files in left to right top to bottom from the above output - if you know what I mean - ie the top row of the output above is represented as the start of the output below....

Code:
 > for lf in $(ls *.log.0??|tail -n 6);do printf '%s ' "$lf";tail -n 1 "$lf";done
h20150126.log.001 23:52:02 completed successfully
h20150129.log.001 20:58:34 completed successfully
h20150201.log.001 23:01:47 completed successfully
h20150204.log.001 05:10:30 completed successfully
h20150207.log.001 05:50:30 JOBFAILURE: COMPLETED WITH ERRORS RC=201
h20150210.log.001 00:57:23 JOBFAILURE: COMPLETED WITH ERRORS RC=201

Don't know why that would be. I tried adding "-l" to the bracketed command - to list one file per line, but that failed spectacularly!

----
Regards,


Ian
This User Gave Thanks to BatterBits For This Post:
 

10 More Discussions You Might Find Interesting

1. UNIX for Advanced & Expert Users

X25 Address - A challenge...

Okay - I've been searching near and far for the answer to this seemly simple question..... how do I find the X25 address for a server. Is there some sort of dump or ping or even a config which would tell me the address. I can find nothing on the web and my colleagues can't help either. (1 Reply)
Discussion started by: peter.herlihy
1 Replies

2. UNIX for Advanced & Expert Users

safeword challenge

Hi, there are some servers here at work which issue a Safeword challenge after I login. Can anyone tell me exactly how the challenge/response system works? In particular, how are the valid keys decided? (2 Replies)
Discussion started by: blowtorch
2 Replies

3. Shell Programming and Scripting

AWK Challenge

I have the following text Microsoft iSCSI Initiator version 2.0 Build 3497 Targets List: iqn.2001-05.com.equallogic:0-8a0906-daef43402-138000002a4477ba-grsrv12-extra iqn.2001-05.com.equallogic:0-8a0906-986f43402-520000002b447951-exchange ... (9 Replies)
Discussion started by: netmedic
9 Replies

4. Shell Programming and Scripting

sed replacement, challenge one!!!!

Hi all, Thanks in advanced. This question really bothered me much. What i want is to replace any times of repeated 'TB' to 'T', below is example. It can be fullfil by AWK and perl, but my desire is using SED to realize it. So here means we treat TB as a whole part, which means 's/TB*/T/'... (4 Replies)
Discussion started by: summer_cherry
4 Replies

5. Shell Programming and Scripting

sed xml challenge

I have a web xml file that looks like this: <allinfo> <info> <a>Name1<\a> <b>address1<\b> <c>phone1<c> <\info> <info> <a>Name2<\a> <b>address2<\b> <c>phone2<c> <\info> <\allinfo> I want to use sed to... (2 Replies)
Discussion started by: katrvu
2 Replies

6. Shell Programming and Scripting

regex challenge

Here's a regex substitution operation that has stumped me with sed: How do you convert lines like this: first.key ?{x.y.z} second.key ?{xa.ys.zz.s} third.key ?{xa.k} to: first.key ?{x_y_z} second.key ?{xa_ys_zz_s} third.key ?{xa_k} So i'm basically converting all the... (11 Replies)
Discussion started by: neked
11 Replies

7. Shell Programming and Scripting

Geo Weather Challenge

Hi everybody, I'm new to these forums and this is my first post. A couple days ago I was trying to find a simple script that would return an individual's local weather conditions using I.P. based geolocation. After many failed search attempts, I began my quest to create this for myself. I have to... (0 Replies)
Discussion started by: o0110o
0 Replies

8. Shell Programming and Scripting

PS1 challenge

Ok then i Have a challenge for you : Give me PS1 so that it always display the least 2 levels of directory (except if i am above of course) I want it this way : so if i go to / /home/ /home/user /home/user/whatever /home/user/whatever1/whatever2 my PS1 should respectively... (12 Replies)
Discussion started by: ctsgnb
12 Replies

9. AIX

openssh connectivity challenge

Running a Power 5 Blade on AIX, with remote connectivity issues via putty. AIX V 6.1.00-02 openssh V5.2.0.5300 openssl V0.9.8.1103 Intermittent remote connections. Seems to connect every other time I try via my putty client. Using hosts.allow and hosts.deny to filter IP Addrss... (2 Replies)
Discussion started by: FrankM
2 Replies

10. UNIX for Dummies Questions & Answers

Touch Challenge

I've been given a directory full of subdirectories full of logfiles of the same name: /logfiles/day1/file1/blockednodes.csv day1-14 file1-48 The above is the actual directory structure for 14 days worth of a logfile that is generated every 30 minutes. It's been done this way to preserve the... (15 Replies)
Discussion started by: Cludgie
15 Replies
SPKAC(1)							      OpenSSL								  SPKAC(1)

NAME
spkac - SPKAC printing and generating utility SYNOPSIS
openssl spkac [-in filename] [-out filename] [-key keyfile] [-passin arg] [-challenge string] [-pubkey] [-spkac spkacname] [-spksect section] [-noout] [-verify] [-engine id] DESCRIPTION
The spkac command processes Netscape signed public key and challenge (SPKAC) files. It can print out their contents, verify the signature and produce its own SPKACs from a supplied private key. COMMAND OPTIONS
-in filename This specifies the input filename to read from or standard input if this option is not specified. Ignored if the -key option is used. -out filename specifies the output filename to write to or standard output by default. -key keyfile create an SPKAC file using the private key in keyfile. The -in, -noout, -spksect and -verify options are ignored if present. -passin password the input file password source. For more information about the format of arg see the PASS PHRASE ARGUMENTS section in openssl(1). -challenge string specifies the challenge string if an SPKAC is being created. -spkac spkacname allows an alternative name form the variable containing the SPKAC. The default is "SPKAC". This option affects both generated and input SPKAC files. -spksect section allows an alternative name form the section containing the SPKAC. The default is the default section. -noout don't output the text version of the SPKAC (not used if an SPKAC is being created). -pubkey output the public key of an SPKAC (not used if an SPKAC is being created). -verify verifies the digital signature on the supplied SPKAC. -engine id specifying an engine (by its unique id string) will cause spkac to attempt to obtain a functional reference to the specified engine, thus initialising it if needed. The engine will then be set as the default for all available algorithms. EXAMPLES
Print out the contents of an SPKAC: openssl spkac -in spkac.cnf Verify the signature of an SPKAC: openssl spkac -in spkac.cnf -noout -verify Create an SPKAC using the challenge string "hello": openssl spkac -key key.pem -challenge hello -out spkac.cnf Example of an SPKAC, (long lines split up for clarity): SPKAC=MIG5MGUwXDANBgkqhkiG9w0BAQEFAANLADBIAkEA1cCoq2Wa3Ixs47uI7F PVwHVIPDx5yso105Y6zpozam135a8R0CpoRvkkigIyXfcCjiVi5oWk+6FfPaD03u PFoQIDAQABFgVoZWxsbzANBgkqhkiG9w0BAQQFAANBAFpQtY/FojdwkJh1bEIYuc 2EeM2KHTWPEepWYeawvHD0gQ3DngSC75YCWnnDdq+NQ3F+X4deMx9AaEglZtULwV 4= NOTES
A created SPKAC with suitable DN components appended can be fed into the ca utility. SPKACs are typically generated by Netscape when a form is submitted containing the KEYGEN tag as part of the certificate enrollment process. The challenge string permits a primitive form of proof of possession of private key. By checking the SPKAC signature and a random challenge string some guarantee is given that the user knows the private key corresponding to the public key being certified. This is important in some applications. Without this it is possible for a previous SPKAC to be used in a "replay attack". SEE ALSO
ca(1) 1.0.0 2009-04-10 SPKAC(1)
All times are GMT -4. The time now is 01:40 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy