Compare commits
5 Commits
claude/fix
...
claude/org
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
e147fcca84 | ||
|
|
696b4d8062 | ||
|
|
3f63c0ce77 | ||
|
|
e00f777cdb | ||
|
|
35602d624f |
2
.github/workflows/deploy-health.yml
vendored
2
.github/workflows/deploy-health.yml
vendored
@@ -22,7 +22,7 @@ jobs:
|
|||||||
- uses: actions/github-script@v7
|
- uses: actions/github-script@v7
|
||||||
with:
|
with:
|
||||||
script: |
|
script: |
|
||||||
const owner = 'peptiderepo';
|
const owner = 'peptide-repo';
|
||||||
const repos = [
|
const repos = [
|
||||||
'prautoblogger','peptide-repo-core','peptide-search-ai',
|
'prautoblogger','peptide-repo-core','peptide-search-ai',
|
||||||
'peptide-news-plugin','peptide-reconstitution-calculator','peptide-starter-theme'
|
'peptide-news-plugin','peptide-reconstitution-calculator','peptide-starter-theme'
|
||||||
|
|||||||
3
.github/workflows/smoke.yml
vendored
3
.github/workflows/smoke.yml
vendored
@@ -53,7 +53,8 @@ jobs:
|
|||||||
run: npm ci
|
run: npm ci
|
||||||
|
|
||||||
- name: Install Playwright browsers
|
- name: Install Playwright browsers
|
||||||
run: npx playwright install chromium --with-deps
|
# OS deps pre-installed on the self-hosted runner host; --with-deps needs sudo which the sandbox blocks
|
||||||
|
run: npx playwright install chromium
|
||||||
|
|
||||||
- name: Run smoke tests
|
- name: Run smoke tests
|
||||||
env:
|
env:
|
||||||
|
|||||||
@@ -1,6 +1,13 @@
|
|||||||
# Changelog
|
# Changelog
|
||||||
|
|
||||||
## [1.7.1] - 2026-06-17
|
## [1.7.2] - 2026-06-17
|
||||||
|
|
||||||
|
### Fixed
|
||||||
|
- **CI**: Drop `--with-deps` from `npx playwright install chromium` in `smoke.yml`.
|
||||||
|
The `peptide-vps` self-hosted runner has OS-level Playwright deps pre-installed by
|
||||||
|
root; `--with-deps` invokes `apt-get` which requires `sudo`, blocked by the runner's
|
||||||
|
`NoNewPrivileges=true` systemd hardening. Binary-only install works without
|
||||||
|
elevated privileges.## [1.7.1] - 2026-06-17
|
||||||
|
|
||||||
### Changed
|
### Changed
|
||||||
- **CI/CD**: Switch `deploy-staging`, `deploy-production`, and `smoke` jobs from
|
- **CI/CD**: Switch `deploy-staging`, `deploy-production`, and `smoke` jobs from
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "peptide-e2e",
|
"name": "peptide-e2e",
|
||||||
"version": "1.7.1",
|
"version": "1.7.2",
|
||||||
"description": "Playwright smoke tests for peptiderepo.com (staging + production)",
|
"description": "Playwright smoke tests for peptiderepo.com (staging + production)",
|
||||||
"private": true,
|
"private": true,
|
||||||
"scripts": {
|
"scripts": {
|
||||||
|
|||||||
@@ -34,7 +34,11 @@
|
|||||||
* The stored OpenRouter key must NEVER appear in page source.
|
* The stored OpenRouter key must NEVER appear in page source.
|
||||||
* #prv_api_key renders with value="" on every page load regardless of
|
* #prv_api_key renders with value="" on every page load regardless of
|
||||||
* whether a key is stored. This spec asserts the empty value and asserts
|
* whether a key is stored. This spec asserts the empty value and asserts
|
||||||
* that known API key prefixes ("sk-or-") are absent from the full body.
|
* that no structurally valid key token (regex /sk-or-v1-[A-Za-z0-9]{20,}/)
|
||||||
|
* appears in the full body HTML. A regex is used instead of a naive
|
||||||
|
* toContain('sk-or-') to avoid a false-positive on the password input's
|
||||||
|
* placeholder="sk-or-…" attribute (the ellipsis is a format hint, not a
|
||||||
|
* token body, and won't match the regex).
|
||||||
*
|
*
|
||||||
* @see peptiderepo/pr-vision includes/core/class-prv-admin-page.php
|
* @see peptiderepo/pr-vision includes/core/class-prv-admin-page.php
|
||||||
* @see peptiderepo/pr-vision includes/core/class-prv-settings-page.php
|
* @see peptiderepo/pr-vision includes/core/class-prv-settings-page.php
|
||||||
@@ -170,10 +174,18 @@ test.describe('WP Admin - PR Vision Settings page (API-key-manager)', () => {
|
|||||||
const inputValue = await keyInput.getAttribute('value');
|
const inputValue = await keyInput.getAttribute('value');
|
||||||
expect(inputValue ?? '').toBe('');
|
expect(inputValue ?? '').toBe('');
|
||||||
|
|
||||||
// Security check: known OpenRouter key prefixes must not appear anywhere in
|
// Security check: a *real* OpenRouter key (format "sk-or-v1-<20+ alnum chars>")
|
||||||
// the page HTML -- guards against accidental server-side leakage.
|
// must not appear anywhere in the page HTML -- guards against accidental
|
||||||
|
// server-side leakage.
|
||||||
|
//
|
||||||
|
// NOTE: We use a regex rather than the naive toContain('sk-or-') to avoid
|
||||||
|
// a false-positive: the password input carries placeholder="sk-or-…"
|
||||||
|
// (an ellipsis format-hint, not a token body) which contains the literal
|
||||||
|
// string "sk-or-" but is NOT a leaked key. A regex that requires the
|
||||||
|
// "v1-" segment and at least 20 alphanumeric characters only matches a
|
||||||
|
// structurally valid key, so the placeholder never trips it.
|
||||||
const html = await page.content();
|
const html = await page.content();
|
||||||
expect(html).not.toContain('sk-or-');
|
expect(html).not.toMatch(/sk-or-v1-[A-Za-z0-9]{20,}/);
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user