Esempio n. 1
0
Variant HHVM_FUNCTION(hash_file, const String& algo, const String& filename,
                                 bool raw_output /* = false */) {
  if (filename.size() != strlen(filename.data())) {
    raise_warning(
     "hash_file() expects parameter 2 to be a valid path, string given"
    );
    return null_variant;
  }
  return php_hash_do_hash(algo, filename, true, raw_output);
}
Esempio n. 2
0
Variant f_hash_file(CStrRef algo, CStrRef filename,
                   bool raw_output /* = false */) {
  return php_hash_do_hash(algo, filename, true, raw_output);
}
Esempio n. 3
0
Variant f_hash(CStrRef algo, CStrRef data, bool raw_output /* = false */) {
  return php_hash_do_hash(algo, data, false, raw_output);
}
Esempio n. 4
0
Variant HHVM_FUNCTION(hash, const String& algo, const String& data,
                            bool raw_output /* = false */) {
  return php_hash_do_hash(algo, data, false, raw_output);
}