hhvm/systemlib-extractor 问题修复 & 功能扩展

解决BUG、新增功能、兼容多环境部署,快速响应你的开发需求

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

hhvm/systemlib-extractor

最新稳定版本:v1.2

Composer 安装命令:

composer require hhvm/systemlib-extractor

包简介

Extract the PHP, Hack, and HNI files embedded in HHVM

关键字:

README 文档

README

Parts of HHVM are implemented in Hack, and are embedded in the HHVM binary as additional ELF PROGDATA sections. This library extracts them from the binary.

There are two kinds of sections that this library extracts:

  • systemlib: Pure Hack code
  • ext: built-in extensions. These are a mix of normal Hack code, and functions annotated with the <<__Native>> user attribute, which are implemented in the C++ runtime

Sections with different names or aren't PROGDATA can not be examined with this library.

Requirements

This package requires the readelf binary; on Debian-like systems, this is in the elfutils package.

Installation

Assuming your project uses Composer:

composer require hhvm/systemlib-extractor

Usage

hphpd> require('vendor/autoload.php')
require('vendor/autoload.php')
hphpd> $extractor = new HHVM\SystemlibExtractor\SystemlibExtractor()
$extractor = new HHVM\SystemlibExtractor\SystemlibExtractor()
hphpd> =$extractor->getSectionNames()
=$extractor->getSectionNames()
HH\Vector Object
(
    [0] => "ext.6eedc03a68a6"
    [1] => "ext.a0e7b2a56511"
    [2] => "ext.7c82e855b041"
...
    [119] => "ext.a6be8a33b7c9"
    [120] => "systemlib"
)

hphpd> =$extractor->getSectionContents('systemlib')
=$extractor->getSectionContents('systemlib')
"<?hh\n// {@}generated\n\nnamespace {\n\n// default base\nclass stdClass {\n}\n\n// used in unserialize() for unknown classes\nclass __PHP_Incomplete_Class {\n  public \$__PHP_Incomplete_Class_Name;\n
There are more characters. Continue? [y/N]n
n
hphpd>

The constructor accepts two optional parameters:

  • a path to an HHVM binary
  • a path to READELF

License

Systemlib-Extractor is BSD-licensed. We also provide an additional patent grant.

Contributing

Please see CONTRIBUTING.md

统计信息

  • 总下载量: 1.22k
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 1
  • 点击次数: 2
  • 依赖项目数: 1
  • 推荐数: 0

GitHub 信息

  • Stars: 1
  • Watchers: 5
  • Forks: 1
  • 开发语言: Hack

其他信息

  • 授权协议: BSD-3-Clause
  • 更新时间: 2015-08-12

承接程序开发

PHP开发

VUE

Vue开发

前端开发

小程序开发

公众号开发

系统定制

数据库设计

云部署

网站建设

安全加固