Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6253193
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 24, 20262026-05-24T13:56:39+00:00 2026-05-24T13:56:39+00:00

I am developing an API using PHP (Codeigniter) and Phils RESTserver. I am creating

  • 0

I am developing an API using PHP (Codeigniter) and Phils RESTserver.
I am creating a hash using crypt() with the password and the salt.

The problem is that the hash that is the result of the crypt() algorithm is different
on my local machine and on the server.

It works fine locally but not on the server (to short). I know the password and the salt are the same because I tried them hardcoded to.

Hash from local machine:

$2a$10$g6J7CUjJvB0JpTd7UcrowePEbqp/oBmZEpd7vS.5HFYx38f08Tb/a

Hash from the server:

$2jkP2/LlC/H6

What can be wrong?

(server is running centos 5).

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-24T13:56:40+00:00Added an answer on May 24, 2026 at 1:56 pm

    Your PHP version probably does not support blowfish hashing for crypt. The $2a$ in the output suggests you’re trying to use CRYPT_BLOWFISH which may not be available on both platforms.

    http://uk.php.net/crypt

    A bug was fixed in PHP 5.3.2:

    Fixed Blowfish behaviour on invalid rounds to return “failure” string
    (“*0” or “*1”), instead of falling back to DES.

    So i’d guess the hash from your server is falling back to DES, since it contains only the first 2 characters of your salt.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm developing a API that uses lambda expressions to specify properties. I'm using this
I'm developing a RESTful API for a client. The problem is, he's using a
I'm using Twitter API with PHP, developing sort of tests. Those test are one
I am developing an API using Codeigniter and in this API the users can
I am developing an REST API using Codeigniter. I need to have all error
I am developing an custom API for a web solution and I am using
I'm developing a twitter messaging utility using Twitter API (twitterizer). But since I'm within
When developing a plug-in to application, using the application API which doesn't run independently
I'm developing a REST api. To simplify my question, I have an API that
Here is my problem: I'm developing a system that can be polled to retrieve

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.