Skip to content

Commit

Permalink
Merge pull request #91 from Toxantron/dev
Browse files Browse the repository at this point in the history
Improvements after release of 2.0
  • Loading branch information
Toxantron authored Sep 29, 2018
2 parents a96dfe9 + 55bfd58 commit 3847a3a
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 2 deletions.
6 changes: 5 additions & 1 deletion src/bootstrap.php
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,11 @@ protected function saveAll(array $entities)
// Create a crypto hash for a secret using the name as salt
protected function createHash($name, $password)
{
return crypt($password, $name);
// Create a safe token from name, password and salt
$token = crypt($name . $password, '$1$ScrumSalt');
$fragments = explode('$', $token);
$hash = $fragments[sizeof($fragments) - 1];
return $hash;
}

// The cookie name of the token for a given session
Expand Down
2 changes: 1 addition & 1 deletion src/templates/master.php
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@

<!-- Invite and statistics -->
<div class="row">
<div class="col-xs-12 col-md-5">
<div class="hidden-xs hidden-sm col-md-5">
<h2>Invite members</h2>
<p>Invite members to join your session. Session id: <strong ng-bind="master.id"></strong></p>
<?php
Expand Down

0 comments on commit 3847a3a

Please sign in to comment.