Kalpdrum Passi

54 papers A 1C 9Misc 1Journal 26Unranked 16
YearRankTypeTitle / Venue / Authors
2025 J jnl
Algorithms
Mehdi Tavafi, Kalpdrum Passi, Robert Ohle
2025 J jnl
Algorithms
Ehsan Kaviani, Kalpdrum Passi
2025 J jnl
Algorithms
Erfan Arbab, Kalpdrum Passi, Robert Ohle
2025 J jnl
CoRR
Kyle Spriggs, Meng Cheng Lau, Kalpdrum Passi
2025 J jnl
Big Data Cogn. Comput.
Maryam Nasourinia, Kalpdrum Passi
2024 J jnl
ACM Trans. Asian Low Resour. Lang. Inf. Process.
Ashwini Kumar, Santosh Kumar, Kalpdrum Passi, Aniket Mahanti
2024 J jnl
IEEE Access
Arunkumar Arulappan, Aniket Mahanti, Kalpdrum Passi, Thiruvenkadam Srinivasan, Ranesh Naha, Gunasekaran Raja
2024 J jnl
Algorithms
Pegah Azami, Kalpdrum Passi
2024 Misc conf
CogSIMA
Elmira Saffarvarkiani, Kalpdrum Passi, Alison Godwin
2023 J jnl
CoRR
Kalpdrum Passi, Shervin Assari, Amir Hossein Zolfaghari
2023 J jnl
IEEE Access
Hossein Chegini, Ranesh Naha, Aniket Mahanti, Mingwei Gong, Kalpdrum Passi
2023 J jnl
Algorithms
Niousha Ghannad, Kalpdrum Passi
2023 J jnl
Algorithms
Aryan Yousefi, Kalpdrum Passi
2022 conf
WWW (Companion Volume)
Bryan White, Aniket Mahanti, Kalpdrum Passi
2022 C conf
IDEAS
Kalpdrum Passi, Aanan Shah
2022 C conf
WEBIST
Drashti Kher, Kalpdrum Passi
2022 J jnl
Symmetry
Arunkumar Arulappan, Gunasekaran Raja, Kalpdrum Passi, Aniket Mahanti
2022 C conf
DATA
Kalpdrum Passi, Rakshit Sorathiya
2022 J jnl
Frontiers Bioinform.
Vishalkumar Vekariya, Kalpdrum Passi, Chakresh Kumar Jain
2022 conf
SAI (2)
Shreya Vaghasia, Kalpdrum Passi
2022 J jnl
Algorithms
Harshkumar Mehta, Kalpdrum Passi
2021 conf
COMS2
Vrushal Shah, Kalpdrum Passi
2021 conf
CSCI
Payal Patel, Kalpdrum Passi, Chakresh Kumar Jain
2020 conf
BIBM
Nakul Patel, Kalpdrum Passi, Chakresh Kumar Jain
2020 J jnl
CoRR
Parth Patel, Kalpdrum Passi, Chakresh Kumar Jain
2020 J jnl
Frontiers Artif. Intell.
Ruihua Guo, Kalpdrum Passi, Chakresh Kumar Jain
2019 conf
BDA
Kalpdrum Passi, Sandipgiri Goswami
2018 J jnl
CoRR
Kalpdrum Passi, Niravkumar Pandey
2018 conf
BIBM
Ojasvi Yadav, Kalpdrum Passi, Chakresh Kumar Jain
2017 conf
BIBM
Kalpdrum Passi, Abdala Nour, Chakresh Kumar Jain
2016 conf
BIBM
Jing Sun, Kalpdrum Passi, Chakresh Kumar Jain
2015 J jnl
Int. J. Heal. Inf. Syst. Informatics
Kalpdrum Passi, Hongtao Zhao
2013 C conf
HIS
Hongtao Zhao, Kalpdrum Passi
2010 J jnl
Int. J. Approx. Reason.
Bhaba Krishna Mohanty, Kalpdrum Passi
2010 C conf
IDEAS
Kalpdrum Passi, Don Morgan
2009 C conf
WEBIST
Preetpal Singh, Kalpdrum Passi
2009 C conf
IDEAS
Kalpdrum Passi, Don Morgan, Sanjay Madria
2008 J jnl
Data Knowl. Eng.
Sanjay Madria, Kalpdrum Passi, Sourav S. Bhowmick
2008 conf
IMCSIT
Tamar Kakiashvili, Waldemar W. Koczkodaj, Phyllis Montgomery, Kalpdrum Passi, Ryszard Tadeusiewicz
2008 conf
SAINT
Sabah Mohammed, Ahmed Orabi, Jinan Fiaidhi, Kalpdrum Passi
2007 conf
AWIC
Ratvinder Singh Grewal, Ryszard Janicki, Tamar Kakiashvili, K. Kielan, Waldemar W. Koczkodaj, Kalpdrum Passi, Ryszard Tadeusiewicz
2007 J jnl
Inf. Syst.
Sanjay Madria, Yan Chen, Kalpdrum Passi, Sourav S. Bhowmick
2006 C conf
ICEC
Bhaba Krishna Mohanty, Kalpdrum Passi
2005 ch.
Encyclopedia of Information Science and Technology (V)
Kalpdrum Passi, Louise Lane, Sanjay Madria, Mukesh K. Mohania
2004 conf
CoopIS/DOA/ODBASE (2)
Kalpdrum Passi, Eric Chaudhry, Sanjay Madria, Sourav S. Bhowmick
2004 conf
International Conference on Internet Computing
Jinan Fiaidhi, Kalpdrum Passi, Sabah Mohammed
2003 A conf
ER
Bipin C. Sakamuri, Sanjay Madria, Kalpdrum Passi, Eric Chaudhry, Mukesh K. Mohania, Sourav S. Bhowmick
2002 conf
EC-Web
Kalpdrum Passi, Louise Lane, Sanjay Madria, Bipin C. Sakamuri, Mukesh K. Mohania, Sourav S. Bhowmick
2002 C conf
DEXA
Yan Chen, Sanjay Madria, Kalpdrum Passi, Sourav S. Bhowmick
2002 conf
WISE Workshops
Sanjay Kumar Madria, Sourav S. Bhowmick, Kalpdrum Passi
1991 J jnl
Int. J. Comput. Math.
M. M. Chawla, Kalpdrum Passi
1991 J jnl
Int. J. Comput. Math.
M. M. Chawla, Kalpdrum Passi
1990 J jnl
Int. J. Comput. Math.
M. M. Chawla, Kalpdrum Passi, R. A. Zalik
1990 J jnl
Int. J. Comput. Math.
M. M. Chawla, Kalpdrum Passi, P. N. Shivakumar
redb/extractors/js_extractors/scripts/js-xray-runner.js
← Index redb/extractors/js_extractors/scripts/js-xray-runner.js javascript
#!/usr/bin/env node
// Bridge between the Python JS pipeline and @nodesecure/js-x-ray.
//
// Usage: node js-xray-runner.js <path-to-js-file>
//   stdout  one JSON object: {"obfuscator": <name|null>, "warnings": [...]}
//   stderr  human-readable error on failure
//   exit 0  analysis ran (the file may still be benign — see "obfuscator")
//   exit 1  the file could not be read or analysed
//
// Each warning is emitted as {kind, value} so the Python side can tag
// supporting signals (encoded-literal, short-identifiers, suspicious-literal,
// unsafe-stmt) without having to mirror js-x-ray's whole schema.
//
// js-x-ray ≥7 ships as an ES module, which CommonJS `require()` cannot load
// from a `.js` script — the dynamic `import()` below is what makes the
// bridge work without renaming the file to `.mjs` or adding `"type":
// "module"` to package.json (which would break tools that still
// `require()` from this directory).

const fs = require("fs");
const path = require("path");

function fail(msg) {
  process.stderr.write(msg + "\n");
  process.exit(1);
}

async function main() {
  const target = process.argv[2];
  if (!target) fail("usage: js-xray-runner.js <file>");

  let source;
  try {
    source = fs.readFileSync(target, "utf8");
  } catch (e) {
    fail(`read failed: ${e.message}`);
  }

  // The legacy `runASTAnalysis` function is deprecated (removed in v8); the
  // current API is the `AstAnalyser` class. Both produce a result with the
  // same `warnings` shape, so the rest of the bridge is unchanged.
  let AstAnalyser;
  try {
    ({ AstAnalyser } = await import("@nodesecure/js-x-ray"));
  } catch (e) {
    fail(`@nodesecure/js-x-ray not installed (run \`npm install\` in ${path.dirname(__filename)}): ${e.message}`);
  }

  // js-x-ray defaults to module-mode parsing, which rejects scripts that
  // (legally) use reserved words as identifiers, top-level `return`, etc.
  // A lot of real-world JS malware is script-style (WScript/HTA bodies,
  // pasted snippets) — retrying in script mode catches those without
  // pulling in a more lenient parser. Both attempts share the same
  // analyser; only the parse mode flips. If both fail, the original error
  // (module-mode) is reported because that's the more informative one for
  // genuinely broken sources.
  let result;
  const analyser = new AstAnalyser();
  let firstErr;
  try {
    result = await analyser.analyse(source, { module: true });
  } catch (e) {
    firstErr = e;
    try {
      result = await analyser.analyse(source, { module: false });
    } catch (e2) {
      fail(`js-x-ray analysis failed: ${firstErr.message}`);
    }
  }

  const warnings = (result.warnings || []).map((w) => ({
    kind: w.kind,
    value: w.value !== undefined ? w.value : null,
  }));

  // js-x-ray flags the obfuscator family in a warning whose kind is
  // "obfuscated-code" and whose value names the family (jsfuck, obfuscator.io,
  // freejsobfuscator, morse, jjencode, ...). Absent => not detected.
  const obfWarning = warnings.find((w) => w.kind === "obfuscated-code");
  const obfuscator = obfWarning ? obfWarning.value : null;

  // js-x-ray runs its own AST internally with a modern parser, so its
  // identifier-length average is the only path the Python pipeline has to
  // that signal on ES2015+ sources — pyjsparser is ES5.1-only and silently
  // drops to 0 the moment it hits destructuring, classes, optional chaining,
  // etc. Surfacing this lets the heuristic's `avg_identifier_length<2`
  // strong signal fire on real obfuscator.io output. `null` when the value
  // is missing or non-numeric (defensive — older js-x-ray builds may differ).
  const idsLengthAvg =
    typeof result.idsLengthAvg === "number" && !Number.isNaN(result.idsLengthAvg)
      ? result.idsLengthAvg
      : null;

  process.stdout.write(JSON.stringify({ obfuscator, warnings, idsLengthAvg }));
}

main().catch((e) => fail(e.message || String(e)));