Hi Everybody!
I want to use Puppeteer github.com/GoogleChrome/puppeteer (with Node.js). This is a Node.js wrapper around Chromium, so my goal is to use Chromium in headless mode. I wrote my sample script, and it works like a charm, if the logged in user has "normal shell", but it gives me false result if the user has Jailed shell.
Of course, I want to use jailed shell in the future, but I also want to use that Puppeteer. My real problem is:
When I run in both normal and jailed shell the script runs without any error. Only the produced image differs: In jailes shell I got white image, in normal shell I got the correct screenhsot.
My node.js code:
So, how can I find which binaries are that Node.js, Puppeteer or Chrome tries to use, but it locates outside of the jail?
After, how I can allow that binaries to run inside jailed shell?
Thanks for your answers!
I want to use Puppeteer github.com/GoogleChrome/puppeteer (with Node.js). This is a Node.js wrapper around Chromium, so my goal is to use Chromium in headless mode. I wrote my sample script, and it works like a charm, if the logged in user has "normal shell", but it gives me false result if the user has Jailed shell.
Of course, I want to use jailed shell in the future, but I also want to use that Puppeteer. My real problem is:
When I run in both normal and jailed shell the script runs without any error. Only the produced image differs: In jailes shell I got white image, in normal shell I got the correct screenhsot.
My node.js code:
Code:
================
'use strict';
const puppeteer = require('puppeteer');
(async () => {
const browser = await puppeteer.launch({
ignoreHTTPSErrors: true,
headless: true,
args: ['--disable-gpu', '--enable-logging', '--no-sandbox', '--disable-setuid-sandbox'],
});
const page = await browser.newPage();
await page.goto('[URL]https://google.com');[/URL]
await page.screenshot({path: 'google.jpg', fromSurface: true});
await page.close();
await browser.close();
})();
================
After, how I can allow that binaries to run inside jailed shell?
Thanks for your answers!
Last edited by a moderator: