| |||||||||||
| |||||||||||
ccrypt with expect Posted by neo (The Architect), 27 August 2005 Has anyone written an expect script that uses 'ccrypt' to encrypt a file.I tried expecting the 'Enter encryption key: ' but the password that I send is then displayed on the screen. ![]() Posted by admin (Graham Ellis), 27 August 2005 Code:
worked for me .... Posted by neo (The Architect), 27 August 2005 I'm using CYGWIN and the code you gave did not work. ![]() It just hangs, I removed the log_user 0 and then saw the password being typed out in plaintext. Posted by admin (Graham Ellis), 27 August 2005 on 08/27/05 at 11:00:24, The Architect wrote:
Expect sits on top of the applications and operating system, and as such it needs fine tuning and adjustment sometimes. Have a careful look at how the script runs without the log_user line and that should lead you to learn where it's failing in more detail, and from that it should lead you to a solution. I'm afraid I don't have Cygwyn to hand, so I can't easily help further with this issue that has turned out to be OS specific. Posted by neo (The Architect), 29 August 2005 I am using the -K option to specify the password along with the command right now.I have another (not actually related) doubt though. Can I pause my script halfway and ask the user for a password and then resume the script? I tried Code:
but it just keeps on in the loop. Posted by admin (Graham Ellis), 29 August 2005 An interact keeps running until it hits a return command in its deffered block. You don't have one, so your interact won't exit.Posted by neo (The Architect), 29 August 2005 ![]() ![]() ![]() Posted by admin (Graham Ellis), 29 August 2005 on 08/29/05 at 11:14:57, The Architect wrote:
Sorry - I mis-spelled that. Should have been deferred rather than deffered. It DID look a bit odd that other way, didn't it? Posted by neo (The Architect), 11 September 2005 Yeah it did. ![]() And yeah I still don't understand it too. ![]() This page is a thread posted to the opentalk forum
at www.opentalk.org.uk and
archived here for reference. To jump to the archive index please
follow this link.
|
| ||||||||||
PH: 01144 1225 708225 • FAX: 01144 1225 793803 • EMAIL: info@wellho.net • WEB: http://www.wellho.net • SKYPE: wellho |