Is it possible to implement web login with apache and Python? Also, how should I receive the input?

Asked 2 years ago, Updated 2 years ago, 16 views

Using Apache to simply display html files or display the results of a Python script was successful. I want to implement login, but there are many things I don't know.

apache2 python

2022-09-21 12:40

1 Answers

What on earth is a login? I used to think that logging in was like magic that you had to use a library. Actually, there's nothing much. When you go to a festival, do you put a paper bracelet on your left wrist? The operation is a login.

Replacing the above real-life case with the login procedure is as follows.

In other words, following requirements are met "login" is an absolute implementation possible.

Now, let me answer the question.

Is it possible to implement web login with apache and Python?

Yes. Perhaps the easiest and most well-known implementation, to handle the 'authentication' procedure, you'll have to decrypt something in the 'request header' called cookie or match it with a server session file. (The context here is that cookies are paper bracelets. The moment the customer tears it up, the moment the cookie is deleted, the user is logged out and is no longer a festival reservation customer.)

How should I receive the input?

There is no correct answer. You just have to get it somehow. If you think about the simplest scenario, you will receive your email, password, and more via a web form called <form method="POST" action="/login">.

Now, if you search for Python auth on Google and look at this and that, flasks can be implemented on top of the framework, or you can just use the Requests module and make it into a blade. But in the end, the nuclei are all the same, so you'll get a sense of what to do. (In the first place, in my experience, it's much more important to understand the overall profile than to technical detail.) If you understand that, coding is not a big obstacle. So I explained it at length above.)

Try it!


2022-09-21 12:40

If you have any answers or tips


© 2024 OneMinuteCode. All rights reserved.