472,330 Members | 1,223 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 472,330 software developers and data experts.

Password protection script

1
Is there any script for protecting a file in Arch Linux? I have important files that I want to, if you open them you must put a password to see the file.
Jul 29 '21 #1
4 8046
Banfa
9,065 Expert Mod 8TB
Try reading this https://www.tecmint.com/file-and-dis...ols-for-linux/

Probably one of your simplest options is to use a tool like 7-Zip to compress the file using encryption and a password. You would then need the password to decrypt the file. That is mentioned on that website. It does ratehr depend on the level of encryption and security you need. And the file type Open Document files can be saved with a password.
Aug 2 '21 #2
SioSio
272 256MB
If the target is a text file, use the vi command to edit the file with the -x option.
Expand|Select|Wrap|Line Numbers
  1. vi -x [file name]
Aug 3 '21 #3
orkann
1 Bit
I think that file compression and password as say Banfa is OK
Aug 19 '21 #4
cetpainfotech
15 Byte
There are several ways to create a password protection script for Linux. One common method is to use the "passwd" command in a shell script. This command can be used to change the password for a user account.

Here is an example of a simple password protection script:

#!/bin/bash
echo "Enter the username:"
read username
echo "Enter the new password:"
read -s password
echo $password | passwd --stdin $username

This script prompts the user to enter a username and a new password, and then uses the "passwd" command to change the password for the specified user.

You can also use other tools like python,bash-scripting,Perl,Java to create a password protection script.

You might also want to consider using a tool such as PAM (Pluggable Authentication Modules) to authenticate users. PAM allows you to use a variety of authentication methods, such as password, SSH keys, or biometrics, and it can be easily configured to work with various types of applications and services.
Jan 28 '23 #5

Sign in to post your reply or Sign up for a free account.

Similar topics

3
by: Wm | last post by:
Something just occurred to me... <yeah, I know, it scared me too> I just password-protected a website by including a password authentication script...
2
by: Boris | last post by:
I am wanting to set up password protection for an area on my website, so only our members can access this area. I am needing to do this using php...
6
by: Lou | last post by:
Please can someone put me out my misery! Im trying to find a multiple user/password protection script that will redirect the specific user to a...
7
by: juglesh | last post by:
<body><div align="center"> <?php if (!isset($password)){ ?><form action="<?php $_SERVER; ?>" method="post"> type password here&nbsp;<input...
2
by: chris | last post by:
Hi, I will be looking to use gatekeeper or some other javascript method of password protection but... Once there I need a way of resticting...
7
by: Borked Pseudo Mailed | last post by:
Seeking feedback on Password Protection via Java/JavaScript ONLY (no cgi): SEE: http://online_tools.home.att.net/tools.html *AND* ...
0
by: btopenworld | last post by:
Hi I have been using two forms of password protection: A) On working web sites I use an ASP script that is included in every page requiring...
0
by: vidhyapriya | last post by:
How do I Compress my Database with password (MS Access Database). Script Below was done if my database unlock with password protection, but when it...
2
by: foekall | last post by:
Dear All, In my office is using Windows Server 2003 with IIS 6.0. When I access IIS 6.0 from internet browser I always need to type user name and...
0
by: tammygombez | last post by:
Hey fellow JavaFX developers, I'm currently working on a project that involves using a ComboBox in JavaFX, and I've run into a bit of an issue....
0
by: concettolabs | last post by:
In today's business world, businesses are increasingly turning to PowerApps to develop custom business applications. PowerApps is a powerful tool...
0
better678
by: better678 | last post by:
Question: Discuss your understanding of the Java platform. Is the statement "Java is interpreted" correct? Answer: Java is an object-oriented...
0
by: teenabhardwaj | last post by:
How would one discover a valid source for learning news, comfort, and help for engineering designs? Covering through piles of books takes a lot of...
0
by: Kemmylinns12 | last post by:
Blockchain technology has emerged as a transformative force in the business world, offering unprecedented opportunities for innovation and...
0
jalbright99669
by: jalbright99669 | last post by:
Am having a bit of a time with URL Rewrite. I need to incorporate http to https redirect with a reverse proxy. I have the URL Rewrite rules made...
0
by: antdb | last post by:
Ⅰ. Advantage of AntDB: hyper-convergence + streaming processing engine In the overall architecture, a new "hyper-convergence" concept was...
2
by: Matthew3360 | last post by:
Hi, I have a python app that i want to be able to get variables from a php page on my webserver. My python app is on my computer. How would I make it...
0
by: AndyPSV | last post by:
HOW CAN I CREATE AN AI with an .executable file that would suck all files in the folder and on my computerHOW CAN I CREATE AN AI with an .executable...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.