
Security News
Suno Breached via Shai-Hulud Worm, Leaked Code Exposes AI Music Scraping
A Shai-Hulud infection exposed Suno's source code, which shows the AI music startup stream-ripped tracks to train its models.
@php-wasm/universal
Advanced tools
@php-wasm/universal contains the runtime pieces shared by @php-wasm/node,
@php-wasm/web, and the Playground client packages.
Most applications should start with loadNodeRuntime() from @php-wasm/node
or loadWebRuntime() from @php-wasm/web. Use this package directly when you
need the lower-level PHP request handler, filesystem helpers, or extension
staging primitives.
External PHP extensions are loaded before PHP starts. They are supported in JSPI runtimes only. A manifest lets a package publish one extension name with artifacts for the PHP version matrix:
{
"name": "wp_mysql_parser",
"version": "0.1.0",
"artifacts": [
{
"phpVersion": "8.4",
"sourcePath": "wp_mysql_parser-php8.4-jspi.so"
}
]
}
sourcePath may be absolute, or relative to the manifest URL. If you pass an
inline manifest instead of manifestUrl, pass baseUrl to choose where
relative artifact files are resolved from.
Asyncify extension loading is reserved for bundled extensions shipped with the
PHP.wasm packages, such as intl, xdebug, redis, and memcached.
resolvePHPExtension() turns bytes, a direct artifact URL, or a manifest into a
ResolvedPHPExtension. withResolvedPHPExtensions() then augments Emscripten
options so the extension .so, generated .ini, sidecar files, and environment
variables are ready before PHP scans its .ini files. When
loadWithIniDirective is false, the .so and sidecar files are still staged
but no .ini file or PHP_INI_SCAN_DIR entry is generated.
import { resolvePHPExtension, withResolvedPHPExtensions } from '@php-wasm/universal';
const extension = await resolvePHPExtension({
phpVersion: '8.4',
source: {
format: 'manifest',
manifestUrl: new URL('https://cdn.example.com/wp_mysql_parser/manifest.json'),
},
});
const emscriptenOptions = withResolvedPHPExtensions({}, [extension]);
Direct bytes skip URL resolution:
await resolvePHPExtension({
phpVersion: '8.4',
name: 'wp_mysql_parser',
source: { format: 'so', bytes },
});
FAQs
PHP.wasm – emscripten bindings for PHP
The npm package @php-wasm/universal receives a total of 54,993 weekly downloads. As such, @php-wasm/universal popularity was classified as popular.
We found that @php-wasm/universal demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 8 open source maintainers collaborating on the project.
Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Security News
A Shai-Hulud infection exposed Suno's source code, which shows the AI music startup stream-ripped tracks to train its models.

Security News
Vercel is formalizing a monthly release program for Next.js. The change follows React2Shell and a sharp rise in AI-assisted vulnerability discovery.

Research
/Security News
11 malicious NuGet tools pose as game cheats to deploy Windows payloads, track hosts, and use Google Sheets for telemetry and control.