.htaccess
AuthName "Restricted Area"
AuthType Basic
AuthUserFile path/.htpasswd
require valid-user
.htpasswd
test:FUgb1Qdh6571o
#This tool is used to generate password file http://tools.dynamicdrive.com/password/
When Apache is running on Windows 10 and I'm trying to access folder authentication dialog appears, however it does not authenticate and does not allow to access restricted folder.
Apache error logs:
AH01617: user test: authentication failure for "/folder": Password Mismatch
Same setup works correctly when Apache is working on Ubuntu
What could be wrong? Different method of password storing?
I don't know about online tool you used, but I recommend to use
htpasswd tool generate passwords.
Appear that test:FUgb1Qdh6571o is generated with algorithm that are not recommended. More info about htpassword could be found at htpasswd docs
To create a new db use:
htpasswd -c .htpasswd test
To update password use:
htpasswd .htpasswd test
PS. I don't recommend to use online passwords generator.
Could be harvested and later used against you.
PS.2 Probably htpasswd command is in apache installation directory
It could be fault of the line ending encoding, which is LF on Linux and CR LF on Windows.
In a hex editor LF would show up as 0a whereas CR LF would be 0d 0a. On Ubuntu you can check with xxd .htpasswd from the terminal and on Windows you can use Notepad++ to show special characters.
Related
After installation of Elasticsearch and running the elasticsearch.bat command. I need to check in https:localhost9200.
Here I am getting a prompt asking for username and password.
Is there any default username or password???
You can Generate a new password using
/usr/share/elasticsearch/elasticsearch-setup-passwords auto/interactive
interactive is where you will have to enter password for all user.
auto will just print passwords on the shell.
else
You can turn off x-pack security in elasticsearch.yml
Answer written by #harshit is correct, Adding more information so that it would be more helpful to the users running ES from code or want more context.
When you run it with source there is default username/password(applicable even in the ES 8.0) as mentioned in the ES code contribution guide and elastic is the default username and password is the default password.
Note that, from ES 8.0 even in Basic and trial ES version x-pack security is enabled by default, and it was disabled before ES 8.0. So if you want to disable it you need to add below setting to your elasticsearch.yml and restart ES.(Not recommended though)
xpack.security.enabled: false
Also, elastic is a reserved username in Elasticsearch, and when you install ES from an archive on *nix based system, its password is not generated due to known issue, but if you running it on Docker or on Windows it would be generated and password will be printed in the cluster logs as explained in official doc, where ES advises to store it in secure location.
For Windows:-
Go to C:\xampp\htdocs\elasticsearch-8.2.2\bin folder.
under the above folder or path open the PowerShell terminal.
Now run this command : .\elasticsearch-reset-password -u elastic .
NOTE - don't forget to add dott (.) at the last.
Then you will see the reset password on the terminal, so now the browser login details will be -
username - elastic // default username
password - new generated token/password
See the Screenshot for reference -
Read More Here:
1-> https://www.elastic.co/guide/en/elasticsearch/reference/current/zip-windows.html#windows-service
2-> https://www.elastic.co/guide/en/elasticsearch/reference/current/built-in-users.html
I am trying to connect by FTP to an Azure Web App. I downloaded the publish profile and copied the login to my FTP client and can connect successfully. But when i use ftp.exe from Windows then i am not able to connect to the same host with the same credentials.
I have read Connecting to Azure website via FTP but those solutions do not fix my problem.
This is the output:
C:\Projects>ftp
ftp> open waws-prod-am2-201.ftp.azurewebsites.windows.net
Connected to waws-prod-am2-201.drip.azurewebsites.windows.net.
220 Microsoft FTP
Service 200 OPTS UTF8 command successful - UTF8 encoding now ON.
User (waws-prod-am2-201.drip.azurewebsites.windows.net:(none)): firstserver\$firstserver
331 Password required
Password:
530 User cannot log in.
Login failed.
Invalid command.
Also tried with username firstserver from the Windows command prompt, no difference. Do not forget: when logging in via commercial FTP client software I CAN login successfully.
I tried backslashing the backslash and/or the dollar sign, but nothing helps. What is going wrong, how do i login from the command prompt using the Windows default ftp.exe?
If you run ftp in debug mode (-d switch), you will see that it truncates the password to 32 characters. That's why the connection fails.
Try using a shorter password. Otherwise you will have to use another command-line FTP client.
We are setting up a system where we need to re-verify a user's identify before he/she is allowed to perform a specific task. The user enters his/her password into the website, and then PHP runs kinit to verify that the password is correct. We use Kerberos for authentication. This is what we successfully tried on a Linux server:
echo "password123" | kinit username#REALM.COM
The problem is that the system is running on a Windows server. We have installed kinit, but cannot seem to get the same thing to work. Running that same command, with or without the quotes, just gives us this output:
kinit: Generic preauthentication failure while getting initial credentials
Any suggestions on what could be done here?
Edit:
Running simply "kinit" and then entering the password at the prompt, works well.
I am trying use the unattended installation for Cognos Business Intelligence 10.1.1. I have the ats file configured and kick-off the installation. The problem is that I cannot seem find an option to provide the DB password in the ATS file. So during the installation, it prompts the user
"Enter the password for [host]\cognos: "
This prevents me from creating an automation script. I see in version 10.2 there seems to be a password section in the ATS file. I tried, but it does not work. Does anyone know how to configure system to avoid the interactive password prompt?
10.2 Sample ATS file (Dialog 9 is password section):
http://www-01.ibm.com/support/knowledgecenter/api/content/SSEP7J_10.2.0/com.ibm.swg.ba.cognos.vvm_installation_guide.10.2.0.doc/c_vvm_sample_response_file.html
I'm very, very new to Amazon EC2, SFTP -- having only used FTP clients until now. I'm trying to log into an Amazon EC2 instance and have everything I needed except a pem file with the key pair, which I have now. However I was told to chmod and reset its permissions to 400 in order to log in correctly. The problem is I have no idea how to go about doing this. There is talk of just entering chmod 400 keyfile.pem through the command line, but is that the Windows command line on my desktop? How can I do this? Any help would be much appreciated...
Either log in using an SSH client (like PuTTY).
Using it, you can execute the command you mention (chmod 400 keyfile.pem) on a command-line.
See also SSH to Amazon EC2 instance using PuTTY in Windows.
Or you can use a GUI SFTP client (like WinSCP) to set the permissions.
See https://winscp.net/eng/docs/ui_properties
Make sure only the R checkbox in Owner row is ticked (that's an equivalent of the 400 permissions in an octal format).
(I'm the author of WinSCP)