Sponsored Content
Top Forums Shell Programming and Scripting Best way to hide password in bash script? Post 302412096 by fubaya on Sunday 11th of April 2010 05:40:33 PM
Old 04-11-2010
Whenever I post a script on my blog and include my email address, I obfuscate it with the tr command to thwart spambots. It could be used here too. If the pass was LinuxRules you could use
Code:
pass=$(echo "LinZxRZles | tr "Z" "u")'

You could also use parameter expansion to pick out the password from a longer random-looking string. None of this provides security, just a little confusion for curious novices.
 

10 More Discussions You Might Find Interesting

1. Programming

hide password typing

I am doing a project in C program which requires to type in password in Unix terminal. Does anybody know how to shade or not output any words typed by user in the terminal? I use the function scan() to read typing from user. Thanks in advance. (2 Replies)
Discussion started by: ivancheung
2 Replies

2. Shell Programming and Scripting

How to hide password on Linux?

Hi falks, I have the following ksh code: echo "Enter VS Admin password:" oldstty=`stty -g` stty -echo intr '$-' read password stty $oldstty echo This code ask from a user to enter his password. The OS suppose to hide the entering of the... (2 Replies)
Discussion started by: nir_s
2 Replies

3. Shell Programming and Scripting

Want to hide password

All, In my script I am calling another script.. in that script I need to enter a password. Problem is that everyone is able to see the password when I enter that. Is there any way that when i enter that password it should not display or may look like *******. Or if there any other way that I... (1 Reply)
Discussion started by: arpitk
1 Replies

4. Shell Programming and Scripting

How Do I Hide the Password in a Script

Hi, I am writing a UNIX .ksh script and need to send the login password of the login id that is executing the script to a command that I am executing in the script. I don't want that password to be seen by anyone except whoever is executing the script. Does anyone know how I can accomplish... (6 Replies)
Discussion started by: samd
6 Replies

5. UNIX for Dummies Questions & Answers

How can i hide username/password

hi all, i run sqlplus command on unix(HP-UX) like "sqlplus username/password@serverA @deneme.sql" but when someone run "ps -ef | grep sqlplus", it can see my username and password :( How can i hide username and password. thanx. (1 Reply)
Discussion started by: temhem
1 Replies

6. Shell Programming and Scripting

How to hide/encrypt password in script?

Hi I have following problem Im writing a script (in bash ) , where need to be written login & passwd for databas client . Its need to in following form login passwd@dbhostname . The problem is so anybody can read it so the passwd & login are visible and thats not very safety . Can... (8 Replies)
Discussion started by: kvok
8 Replies

7. Shell Programming and Scripting

Expect Script - Hide password from process table

i have an expect script that runs like this: /usr/bin/expect -f /home/skysmart/commandstoexecute.sh host2.net b$4aff Skysmart when i run this command, and i do a ps -ef and egrep for expect, i see the exact line in the process table and it shows my password for the world to see. how can i... (2 Replies)
Discussion started by: SkySmart
2 Replies

8. Shell Programming and Scripting

Make a password protected bash script resist/refuse “bash -x” when the password is given

I want to give my long scripts to customer. The customer must not be able to read the scripts even if he has the password. The following command locks and unlocks the script but the set +x is simply ignored. The code: read -p 'Script: ' S && C=$S.crypt H='eval "$((dd if=$0 bs=1 skip=//|gpg... (7 Replies)
Discussion started by: frad
7 Replies

9. Shell Programming and Scripting

Hide password from processes in Linux

i have a shell script which calls a java program with username and password arguments. #!/bin/ksh #set some classpaths here #finally run the command java com.test -u $U -p $P Now when i run it, the password shows up in the list of processes. I am not the admin on the server so cant... (3 Replies)
Discussion started by: ariesb2b
3 Replies

10. Shell Programming and Scripting

How to hide password in shell script?

I am writing a shell script for sql loader (just copy part of the code) : For security reason, I have to put the below loginName and password into another separate file instead of in the same file of this script. Anyone can give me a hand. Thanks. Shell Script :... (12 Replies)
Discussion started by: Jaewong
12 Replies
BLAZE-CONFIG(1) 					    BlazeBlogger Documentation						   BLAZE-CONFIG(1)

NAME
blaze-config - displays or sets BlazeBlogger configuration options SYNOPSIS
blaze-config [-qV] [-b directory] [-E editor] option [value...] blaze-config -e [-b directory] blaze-config -h|-v DESCRIPTION
blaze-config either sets BlazeBlogger configuration options, or displays their current value. Additionally, it can also open a configuration file in an external text editor. OPTIONS
Command Line Options -b directory, --blogdir directory Allows you to specify a directory in which the BlazeBlogger repository is placed. The default option is a current working directory. -E editor, --editor editor Allows you to specify an external text editor. When supplied, this option overrides the relevant configuration option. -e, --edit Allows you to edit the configuration in a text editor. -q, --quiet Disables displaying of unnecessary messages. -V, --verbose Enables displaying of all messages. This is the default option. -h, --help Displays usage information and exits. -v, --version Displays version information and exits. Configuration Options blog.title=string A title of your blog. blog.subtitle=string A subtitle of your blog. blog.description=string A brief description of your blog. blog.keywords=list A comma-separated list of keywords. blog.theme=string A theme for your blog. Note that it must point to an existing file in the ".blaze/theme/" directory. The default option is "default.html". blog.style=string A style sheet for your blog. Note that it must point to an existing file in the ".blaze/style/" directory. The default option is "default.css". blog.lang=string A translation of your blog. Note that it must point to an existing file in the ".blaze/lang/" directory. The default option is "en_US". blog.posts=integer A number of blog posts to be listed on a single page. The default option is 10. color.list=boolean A boolean to enable ("true") or disable ("false") colors in the blaze-list output. The default option is "false". color.log=boolean A boolean to enable ("true") or disable ("false") colors in the blaze-log output. The default option is "false". core.doctype=string A document type. It can be either "html" for HTML, or "xhtml" for the XHTML standard. The default option is "html". core.extension=string A file extension. The default option is "html". core.encoding=string A character encoding. Note that it has to be in a form that is recognized by W3C standards. The default option is "UTF-8". core.editor=string An external text editor. When supplied, this option overrides the system-wide settings. core.processor=string An external application to be used to process newly added or edited blog posts and pages. Note that you must supply "%in%" and "%out%" in place of an input and output file name respectively. This option is disabled by default. feed.baseurl=string A URL of your blog, for example "http://example.com". feed.posts=integer A number of blog posts to be listed in the feed. The default option is 10. feed.fullposts=boolean A boolean to enable ("true") or disable ("false") inclusion of the whole content of a blog post in the feed, even though the <!-- break --> form is used. The default option is "false". post.author=string A location of a blog post author name. It can be placed above the post ("top"), below it ("bottom"), or nowhere on the page ("none"). The default option is "top". post.date=string A location of a date of publishing. It can be placed above the post ("top"), below it ("bottom"), or nowhere on the page ("none"). The default option is top. post.tags=string A location of post tags. They can be placed above the post ("top"), below it ("bottom"), or nowhere on the page ("none"). The default option is "top". user.name=string Your full name to be used in the copyright notice, and as the default post author. The default option is "admin". user.nickname=string Your nickname to be used as the default post author. When supplied, it overrides the user.name setting. This option is disabled by default. user.email=string Your email address. The default option is "admin@localhost". ENVIRONMENT
EDITOR Unless the core.editor option is set, BlazeBlogger tries to use system-wide settings to decide which editor to use. FILES
.blaze/config A file containing the configuration. .blaze/theme/ A directory containing blog themes. .blaze/style/ A directory containing style sheets. .blaze/lang/ A directory containing language files. EXAMPLE USAGE
Configure the default text editor: ~]$ blaze-config core.editor nano The option has been successfully saved. Configure the user information: ~]$ blaze-config user.name Jaromir Hradilek The option has been successfully saved. ~]$ blaze-config user.email jhradilek@gmail.com The option has been successfully saved. Configure the blog appearance: ~]$ blaze-config blog.title BlazeBlogger The option has been successfully saved. ~]$ blaze-config blog.subtitle a CMS without boundaries The option has been successfully saved. ~]$ blaze-config blog.theme keepitsimple.html The option has been successfully saved. ~]$ blaze-config blog.style keepitsimple.css The option has been successfully saved. Configure the RSS feed: ~]$ blaze-config feed.fullposts true The option has been successfully saved. ~]$ blaze-config feed.posts 10 The option has been successfully saved. ~]$ blaze-config feed.baseurl http://blaze.blackened.cz/ The option has been successfully saved. Open the configuration in a text editor: ~]$ blaze-config -e SEE ALSO
blaze-init(1) BUGS
To report a bug or to send a patch, please, add a new issue to the bug tracker at <http://code.google.com/p/blazeblogger/issues/>, or visit the discussion group at <http://groups.google.com/group/blazeblogger/>. COPYRIGHT
Copyright (C) 2008-2011 Jaromir Hradilek This program is free software; see the source for copying conditions. It is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. Version 1.2.0 2012-03-05 BLAZE-CONFIG(1)
All times are GMT -4. The time now is 01:00 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy