T.ME/BIBIL_0DAY
CasperSecurity


Server : Apache/2
System : Linux server-15-235-50-60 5.15.0-164-generic #174-Ubuntu SMP Fri Nov 14 20:25:16 UTC 2025 x86_64
User : gositeme ( 1004)
PHP Version : 8.2.29
Disable Function : exec,system,passthru,shell_exec,proc_close,proc_open,dl,popen,show_source,posix_kill,posix_mkfifo,posix_getpwuid,posix_setpgid,posix_setsid,posix_setuid,posix_setgid,posix_seteuid,posix_setegid,posix_uname
Directory :  /home/gositeme/domains/lavocat.ca/public_html/scripts/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Current File : /home/gositeme/domains/lavocat.ca/public_html/scripts/fetch-missing-lawyer-image-urls.js
const axios = require('axios');
const cheerio = require('cheerio');

const BASE_URL = 'https://www.adwavocats.com';
const TEAM_URL = BASE_URL + '/a-propos/';

const missingLawyers = [
  'marie-claude-tremblay',
  'david-chen',
  'sophie-dubois',
  'marc-andre-bouchard',
  'isabella-rodriguez',
  'thomas-leblanc',
  'antoine-duranleau-hendrickx',
  'ivan-lazarov',
  'yalda-machouf-khadir',
  'olivia-malenfant',
  'imane-melab',
  'mmah-nora-toure'
];

function slugify(str) {
  return str
    .toLowerCase()
    .replace(/é/g, 'e')
    .replace(/è/g, 'e')
    .replace(/ê/g, 'e')
    .replace(/à/g, 'a')
    .replace(/ç/g, 'c')
    .replace(/ô/g, 'o')
    .replace(/î/g, 'i')
    .replace(/ï/g, 'i')
    .replace(/'/g, '')
    .replace(/[^a-z0-9]+/g, '-')
    .replace(/^-+|-+$/g, '');
}

(async () => {
  const { data: html } = await axios.get(TEAM_URL);
  const $ = cheerio.load(html);
  $('img').each((i, el) => {
    const alt = $(el).attr('alt') || '';
    let src = $(el).attr('src') || '';
    let srcset = $(el).attr('srcset') || '';
    let dataSrc = $(el).attr('data-src') || '';
    let name = alt.replace(/(Me |Avocat|Avocate|Me\.|Mme\.|M\.|\(.*\))/gi, '').trim();
    const slug = slugify(name);
    if (missingLawyers.includes(slug)) {
      let imageUrl = null;
      if (srcset && srcset.includes('.webp')) {
        imageUrl = srcset.split(',').find(s => s.includes('.webp')).split(' ')[0];
      } else if (src.endsWith('.webp')) {
        imageUrl = src;
      } else if (dataSrc.endsWith('.webp')) {
        imageUrl = dataSrc;
      } else if (src) {
        imageUrl = src;
      }
      if (imageUrl) {
        if (!imageUrl.startsWith('http')) imageUrl = BASE_URL + imageUrl;
        console.log(`${slug}: ${imageUrl}`);
      }
    }
  });
})(); 

CasperSecurity Mini