Hack Forums
[PHP] SecureYou 1.0 | PHP Library To Login/Register - Printable Version

+- Hack Forums (https://hackforums.net)
+-- Forum: Tech (https://hackforums.net/forumdisplay.php?fid=444)
+--- Forum: Coding (https://hackforums.net/forumdisplay.php?fid=151)
+---- Forum: Web Development (https://hackforums.net/forumdisplay.php?fid=183)
+---- Thread: [PHP] SecureYou 1.0 | PHP Library To Login/Register (/showthread.php?tid=5600832)

Pages: Pages 1 2 3 4


* - alemalakra - Apr 17, 2017

(Apr 17, 2017 07:33 PM)Aces. Wrote:  Big up for giving constructive criticism, who knows the class might even be popular in the future?

Keep working OP and learn how to handle criticism, I believe in you, the trick to success is time and effort which means if you put enough time into it then one day it'll be one of a kind.

Wise advices!! Greetings !, I will continue working on this, successes


* - Uefi - Apr 17, 2017

Use bcrypt to hash your passwords, a secure standardized hashing algorithm is the proper procedure; don't encrypt them, especially with a one-time pad.


* - alemalakra - Apr 17, 2017

(Apr 17, 2017 09:08 PM)Uefi Wrote:  Use bcrypt to hash your passwords, use a secure standardized hashing algorithm don't encrypt them, especially with a one-time pad.

At this time, the project is using password_hash(), you can see it yourself from the class in github


* - Uefi - Apr 17, 2017

PHP Code

<?php 
function encrypt($string) //Hashing, encryption, what's the difference! -OP 

PHP Code

<?php 
if($stmt->rowCount() > 0){
            
$testone = true;
            return 
true;
        } else {
            
$testone = false;
        }
 
//Expressions are evaluated within the if statement, you also for some reason declared a new variable as bool then returned another matching bool, redeclared if false and returned nothing. Genius. 

PHP Code

<?php 
$session 
= sub str(md5(rand()), 0, 35) //Where do I even go with this? 

MineSQL you want to talk about OOP and PDO yet let this slide?
Half of the errors are so bad HF's firewall catches me.
Don't use this class.
/thread


* - alemalakra - Apr 17, 2017

(Apr 17, 2017 09:19 PM)Uefi Wrote:  
PHP Code

<?php 
function encrypt($string) //Hashing, encryption, what's the difference! -OP 

PHP Code

<?php 
if($stmt->rowCount() > 0){
            
$testone = true;
            return 
true;
        } else {
            
$testone = false;
        }
 
//Expressions are evaluated within the if statement, you also for some reason declared a new variable and if it's true returned another bool. Genius. 

PHP Code

<?php 
$session 
= sub str(md5(rand()), 0, 35) //Where do I even go with this? 

MineSQL you want to talk about OOP and PDO yet let this slide?
Half of the errors are so bad HF's firewall catches me.
Don't use this class.
/thread

Please, I do not want you to insult my code, I brought it for the new ones, so that they can login / register, I hope you understand, thank you


* - Uefi - Apr 17, 2017

(Apr 17, 2017 09:27 PM)alemalakra Wrote:  Please, I do not want you to insult my code, I brought it for the new ones, so that they can login / register, I hope you understand, thank you

You are a new one, not only is it all redundant, breaking almost every standard, not have try nor catch blocks, you have random vague variables and arrays everywhere making your code impossible to follow.

Read the PHP Documentation:
https://secure.php.net/docs.php

Get up to standards:
http://www.php-fig.org/psr/

Learn the proper way query logic should be performed.
Then post your code for the community to use.


* - alemalakra - Apr 18, 2017

(Apr 17, 2017 09:27 PM)Uefi Wrote:  You are a new one, not only is it all redundant, breaking almost every standard, not have try nor catch blocks, you have random vague variables and arrays everywhere making your code impossible to follow.

Read the PHP Documentation:
https://secure.php.net/docs.php

Get up to standards:
http://www.php-fig.org/psr/

Learn the proper way query logic should be performed.
Then post your code for the community to use.

New? Lol, I guess it's a bit more than you, but hey, nowadays everyone feels master, please, retire from my thread, if the code is bad, I just do not use it, Regards


* - ASDA - Apr 18, 2017

(Apr 18, 2017 02:24 AM)alemalakra Wrote:  New? Lol, I guess it's a bit more than you, but hey, nowadays everyone feels master, please, retire from my thread, if the code is bad, I just do not use it, Regards

itt op is a fucking idiot

/thread


* - Sapience - Apr 18, 2017

Believe it or not, this thread has been a pretty good reference. Just not in the way OP intended.

Thanks for reacting to this thread, everyone, and telling people about some of the things not to do :D


* - Bluffer - Apr 18, 2017

Why is it that UB3R members have to be such ass holes to new members who are doing nothing more than trying to help the community?

There are better ways to explain that his code is not secure or doesn't meet standards than completely insulting him.


* - Corrupt3d - Apr 18, 2017

peeps are trying to help you calm your horses OP


* - elunez - Apr 18, 2017

(Apr 18, 2017 02:24 AM)alemalakra Wrote:  New? Lol, I guess it's a bit more than you, but hey, nowadays everyone feels master, please, retire from my thread, if the code is bad, I just do not use it, Regards

Well, reading your code, i dont think you are experienced developer at all.

Keep learning, as other people suggested - dive into OOP and design patterns, the current situation of your code is beyond terrible, tbh if you need to change it - you have to rewrite it completely.


* - alemalakra - Apr 18, 2017

(Apr 18, 2017 11:52 AM)Sapience Wrote:  Believe it or not, this thread has been a pretty good reference. Just not in the way OP intended.

Thanks for reacting to this thread, everyone, and telling people about some of the things not to do :D



Thanks! Regards


(Apr 18, 2017 02:20 PM)Βluffer Wrote:  Why is it that UB3R members have to be such ass holes to new members who are doing nothing more than trying to help the community?

There are better ways to explain that his code is not secure or doesn't meet standards than completely insulting him.

Thanks for understand! Regards!


(Apr 18, 2017 04:25 PM)elunez Wrote:  Well, reading your code, i dont think you are experienced developer at all.

Keep learning, as other people suggested - dive into OOP and design patterns, the current situation of your code is beyond terrible, tbh if you need to change it - you have to rewrite it completely.

I always like to contribute, daily I see how to improve, greetings !, apologize if I said that, I do not really care who is better, we can all be good ..


* - Nachfolger - Apr 20, 2017

To everyone being harsh on op, he's just trying to build a login system. If all you're gonna do is come here and say he sucks and to give up then gtfo.

OP, good luck.


* - alemalakra - Apr 20, 2017

(Apr 20, 2017 04:05 AM)Yani Wrote:  He isn't just trying to build a login system, he's releasing a bad and insecure script and claims it's good, which it isn't.

People wouldn't mind if he were to share his code and just ask for feedback, but instead OP decided to release it and even use "secure" in the name..

Tell me, how insecure is it? If you answer me that you will have the reason lol, it is for the passwords? Look at the code again .... if you do not know do not speak, regards