Code

Discussion on Advanced Security - PHP Register/Login System

Discussion on Advanced Security - PHP Register/Login System

Cart 2,756 sales

niftycode supports this item

Supported

This author's response time can be up to 1 business day.

1144 comments found.

Does the Advanced Security – PHP Register/Login System allow an administrator to approve a registration before it is approved?

Hey,

As you can see in demo, there is no such thing built into the app out of the box. You will have to implement that additional step yourself.

Regards,

Milos

Hey version 2.3,Form serialization does not work。 Installation tips are not available This is my installation encountered problems。 Thank you very much。 Regards,

penguin563

Hey, I offer you a link to my test. Installation step2,No tips,chrome v57.XXX http://50.6.180.171/install/index.php

Thank you very much。 Regards,

penguin563

Hey,

It has nothing to do with AS version. There are problems with your server configuration, and older AS versions won’t work there too. Are you sure that your permissions are properly set for PHP, js and other files and that they are executable?

You should also check your server log, since the HTTP request which is responsible for fetching server info from your server is returning 500 server error.

Regards,

Milos

Hey,

I like your source code.I bought it But can only be downloaded to version 2.3 Can you give me the old version?(Version 1.1 、1.2、1.3、2.0、2.1 2.2)

My Email:bcsdue1982@gamil.com

Thank you very much。

Regards,

penguin563

Hey,

You can only download the latest version of the script, which is what I recommend too. I can probably pull the older versions from VCS, by it’s really not recommended to use them instead of the latest version.

Is there any particular reason why you would want those versions?

Regards,

Milos

Hey, because 1.Completely new installation wizard→style and vue.js(More than the scope of my ability),but vue.js is good 。 2.Minimum PHP version required is now PHP 5.3z

3.new versions installation wizard has a problem. in new versions chrome or ie

maybe Ajax… The installation can not display the error

Regards,

penguin563

Hi. As an admin, I would like to receive an email each time a new user registers.

I tried hacking “ASRegister.php” file, inserting a php mail function at the end of “public function register($data)”, but had no success.

Can you show me how to do it? In the future, I will need to post a request to Slack after each registration as well, so I need advice.

Thanks!

UPDATE: 1) Nevermind the first question. I inserted the mail() function after the “return” statement…so dummy!

Hey,

I don’t have any update planned for near future, except if it has to be released in case of some security fix or something. But even if I release it, there won’t be a lot of modifications inside the source code for sure.

Regards,

Milos

Hey,

I don’t have any update planned for near future, except if it has to be released in case of some security fix or something. But even if I release it, there won’t be a lot of modifications inside the source code for sure.

Regards,

Milos

Hi Milos,

Recently I couldn’t add new user in the admin panel. After filling info sot the new user such as email, username and pass, I press ADD. I received no error, but the new user didn’t appear in the user list.

Please advise, Thanks so much

Hey,

AS uses MySQL auto-increment fields for such things, and it does not take such things into account. Thats really something you should not worry about, since it don’t affect how application works at all.

Regards,

Milos

Milos, Thanks so much for your help so far. I have another thing arose when developing my application using your very great framework. I saw in the documentation that we can perform methods such as $db->insert for INSERT, $db->update for UPDATE etc. My question is that could In perform ALTER and other standard SQL queries by using the ”$db->” syntax? Yes because I need more tables in the database and I love the way you code to query. Many thanks!

Hey,

Of course you can. ASDatabase class extends PDO, and you can use any PDO method you want. Check http://docs.as-php.com/database-queries.html#database-queries, there is link to PDO documentation available on that page.

Regards,

Milos

Hi There, I am having an issue installing the Advanced Security PHP Register/Login System. I have gone through the installation process but after clicking install the button continues to keep saying installing with an icon rotating. For more than one hour now.

I get this erros message in the debugging console of the browser

SCRIPT5007: Unable to get property ‘message’ of undefined or null reference install.js (129,21) SCRIPT5007: Unable to get property ‘message’ of undefined or null reference

Hey,

There is some error with it, installation should not take more than a second or two.

Please check this section on how to debug ajax requests: http://docs.as-php.com/developer-guide.html#debugging-ajax-requests

Now, when you open Chrome Dev Tools, and you are monitoring the Network tab, run the installation again and let me know which errors you get on request that is being sent when you click “Install” button.

Regards,

Milos

OK sorted it out, install folder was not accesable

Hi loshMiS,

I finished installation without any error, but failed to login using admin account. It said “Wrong user/pass combination”. What should I do next?

Thanks for the hint Milos!!! I got 500 Internal Error message, and the process stops at ASAjax.php in ASEngine folder. Thanks for your very fast response btw!

Milos, I figured it myself. It’s about improper folder and file permission. Logged in admin panel now. Thanks for your great help!

Hey,

Great! I’m glad that it is working now. :)

Regards,

Milos

Hey, is there a way to disable the CSRF Protection?

Hey,

It’s not recommended to do such thing, but if you want it then just remove the following code from ASEngine/AS.php file:

if ($_SERVER['REQUEST_METHOD'] == 'POST' && ! ASCsrf::validate($_POST)) {
    die('Invalid CSRF token.');
}

Regards,

Milos

Perfect, thanks.

Hi, do you provide support for errors from adding to your code? I added a file submission form to index.php. However when I press submit I get invalid CSRF token. Can you help?

Awesome thank you. Worked great!

It seems to only semi-work. I still get Invalid CSRF token when uploading large files. It seems files under ~5MB work fine. My max is set to 60GB right now but I can’t upload anything over 5MB. My php.ini is also set to 60GB. Is there a setting or something I need to change in your code? Or is it a problem elsewhere?

Hey,

CSRF token has nothing to do with file upload limit. There is probably something wrong with your PHP configuration. 60 GB is really huge limit, isn’t it maybe 60MB? Don’t forget that, if you want to set the upload file limit to 10 MB for example, you have to modify the following two php.ini parameters:

upload_max_filesize = 10M
post_max_size = 10M

If you update only one parameter it won’t work properly.

Regards,

Milos

I’m using the old version I have found a problem when checking if username exist.

In latin language like french username may have accent letters like é

Let say I have a user that have username Romeo if I edit the username of this user to Roméo and Save I’m getting username exist so I cannot save the username. Is there a way to fix that.

I know in fact that when logging it does not check accent/capital letter for username. On new system I can prevent user enter accent letter but in some existing system I may have username with accent.

Any solution is welcome, thanks.

Also to my opinion space should not be permit inside username. This can happen when user copy paste for example we can enter ‘jane doe’ as username and save then try to login with ‘janedoe’ and it’s not working. try to login with ‘jane doe’ it’s working

Hey,

In that case set the collation for username field to utf8_bin and it will work like a charm.

About space in username, that’s entirely up to you to modify it to fit your needs. From my point of view, I don’t see why you would want to limit the user not to use spaces inside the username, since if I want to have my username be “john doe”, there is nothing wrong with it. But again, if you want you can customize it and not allow spaces.

Regards,

Milos

Hi,

Can I change utf8_unicode_ci to utf8_general_ci

For those users columns with no problem?

password confirmation_key password_reset_key

Just because I’m using utf8_general_ci everywhere else just to be uniform.

Lert say I switch to utf8_unicode_ci does utf8mb4_unicode_ci will work ok with you code?

Hey,

It should work just fine, but you will have to test it yourself.

Regards,

Milos

Hello,

I am executing couple of ajax calls in a js file, and it keeps sending me to the login page after I refresh the page. Is ajax interfering with PHP Session, or what is going on?

Thanks!

Hey,

I’m really not sure what is causing issue then. You can enable error reporting in PHP, and then debug ajax requests by using browser’s developer tools, to see if there are some errors returned from the server. It’s probably because of some errors, since it is working properly on other ajax requests you have.

Regards,

Milos

Hey,

I have figured out the problem, but I don’t know why it is like this. In the new version, I have seen you have removed the session_regenerate_id, because this was causing the problem with refreshing while ajax calls were executing. Do you know why this was happening, and what purpose does the session_regenerate_id have?

Hey,

When you set session_regenerate_id to true, it will regenerate session id on each request. On some servers it can cause problems, and that’s why I removed it, since session is already regenerating the id after you log in successfully (which is an important thing to prevent session fixation).

You can just set it to false in your version and you don’t have to worry about it.

Regards,

Milos

Hi there

So, I have purchased and installed the Advanced PHP version. How do I actually assign permission to certain page now? Say I have created page1.php how do I give access to this page to certain role?

Hey,

Please check the docs available here: http://docs.as-php.com/authorization.html

Basically you can do something like:


//...
$role = app('current_user')->role;

if ($role != 'user') {
    redirect("some_other_page.php");
}

Regards,

Milos

I am looking to purchase the advanced security php register and login system. My question when a user creates an account I am sure the system will send a email for the user to click and they can log into the account, is it possible to setup another level of security to make sure they are a member before you grant them full access within the admin area?

We want a human to check their access first.

Hey,

Yeah, the app works as you described it. Of course it is possible to have it work like that, but you will have to implement that from scratch, since it does not come with the script out of the box.

Regards,

Milos

Please ignore my question I have deleted, I realized my problem occurs only if the same browser is use.

yes,

Wanted to know why the reset password or receiving the token takes about 5 minutes.

help

Hey,

It only depends on your mail server. For some reason, your mail server does not send the email immediately, or, it sends it but there is some delay there for some reason. In any case, this is not related to the AS.

Regards,

Milos

Hi I have a question about private function exist is there a way to check more than 1 table / column? The case: server side validation, I want to check something prior deleting if exist in these specific tables/columns I won’t allow the delete.

Hey,

As you can see by checking the function’s source code, it’s doing simple SELECT query, so it’s not quite possible to achieve what you want. You will have to modify it a bit to fit your needs, or to create completely different function.

Regards,

Milos

Ok thanks

Hello,

I just successfully installed the script and when i try to login with the test account nothing happens. I found a POST in the chrome dev console and looking at the response it says ‘Invalid CSRF token.’

Any help would be greatly appreciated.

So i just hopped in the code and followed it a bit. I enabled DEBUG in AS.php and reloaded the login page. A few errors display but I believe it all stemming from the first one:

Failed to write session data (files). Please verify that the current setting of session.save_path is correct (D:\Temp\php\session\) in Unknown on line 0

I just ran a phpinfo() and that is indeed the session.save_path. It also says that session support is enabled.

Hey,

So it looks like it is something related to PHP configuration, since PHP is not able to start the session. Try to change the session.save_path to point to some other folder where PHP can write, and restart PHP. It should solve the problem.

Regards,

Milos

That was it, thanks!!

Hello Milos, I am using your script for a non-profit, hobby website.

But now I am making a website for my business. The concept is that I build personalized databases for clients.

I want to have a very secure login system, and I am familiar with your script. My question is, if I were to use AS for my business site, which license would I need to purchase?

Hey,

For your business website you need to purchase extended license only if end users are going to be charged for using the website/app. If your business website/app is free for anyone to use it (if users don’t have to pay for any feature on your website) then regular license is way to go.

Regards,

Milos

Milos, thank you for your reply.

I’m still not clear, because clients will not be charged to use the website, but charged for my services. The service is doing a literature search for clients. I will use a database to display the results of my literature search.

The website is a way for clients to contact me to request my services. But I do want them to be able to log in to access their personalized databases.

Hey,

Well in that case regular license should be fine, but I recommend you to contact Envato support and ask them. They will help you and explain you everything you need to know.

Regards,

Milos

I am sorry I don’t get it. I am trying to implement your scripts or copy and paste your scripts to the site or our website and i can’t find the classes and the app folder? i think. I installed everything, everything works but don’t know how to connect it our website, let alone add the log out buttons to the website…..I don’t know…...

Confused

Hey,

I’m sorry for my late response. I was on vacation, As you could see when you posted this comment.

About the problem you have, I’m not sure that I completely understand it… There is no app folder inside AS script (and it should not be there by default). Have you checked the docs: http://docs.as-php.com ?

Regards,

Milos

by
by
by
by
by
by

Tell us what you think!

We'd like to ask you a few questions to help improve CodeCanyon.

Sure, take me to the survey