<ul dir="auto">
<li>Output of <code class="notranslate">node_modules/.bin/electron --version</code>: v4.0.1</li>
<li>Operating System (Platform and Version): OSX Mojave</li>
<li>Output of <code class="notranslate">node_modules/.bin/electron --version</code> on last known working Electron version (if applicable): N/A</li>
</ul>
<p dir="auto"><strong>Expected Behavior</strong><br>
A clear and concise description of what you expected to happen.</p>
<p dir="auto">I'd expect that hash algorithms available to Electron would mirror those available to Node v10.11.0. So, something like:</p>
<div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="&gt; c.getHashes();
[ 'RSA-MD4',
  'RSA-MD5',
  'RSA-MDC2',
  'RSA-RIPEMD160',
  'RSA-SHA1',
  'RSA-SHA1-2',
  'RSA-SHA224',
  'RSA-SHA256',
  'RSA-SHA384',
  'RSA-SHA512',
  'blake2b512',
  'blake2s256',
  'md4',
  'md4WithRSAEncryption',
  'md5',
  'md5-sha1',
  'md5WithRSAEncryption',
  'mdc2',
  'mdc2WithRSA',
  'ripemd',
  'ripemd160',
  'ripemd160WithRSA',
  'rmd160',
  'sha1',
  'sha1WithRSAEncryption',
  'sha224',
  'sha224WithRSAEncryption',
  'sha256',
  'sha256WithRSAEncryption',
  'sha384',
  'sha384WithRSAEncryption',
  'sha512',
  'sha512WithRSAEncryption',
  'ssl3-md5',
  'ssl3-sha1',
  'whirlpool' ]"><pre class="notranslate"><code class="notranslate">&gt; c.getHashes();
[ 'RSA-MD4',
  'RSA-MD5',
  'RSA-MDC2',
  'RSA-RIPEMD160',
  'RSA-SHA1',
  'RSA-SHA1-2',
  'RSA-SHA224',
  'RSA-SHA256',
  'RSA-SHA384',
  'RSA-SHA512',
  'blake2b512',
  'blake2s256',
  'md4',
  'md4WithRSAEncryption',
  'md5',
  'md5-sha1',
  'md5WithRSAEncryption',
  'mdc2',
  'mdc2WithRSA',
  'ripemd',
  'ripemd160',
  'ripemd160WithRSA',
  'rmd160',
  'sha1',
  'sha1WithRSAEncryption',
  'sha224',
  'sha224WithRSAEncryption',
  'sha256',
  'sha256WithRSAEncryption',
  'sha384',
  'sha384WithRSAEncryption',
  'sha512',
  'sha512WithRSAEncryption',
  'ssl3-md5',
  'ssl3-sha1',
  'whirlpool' ]
</code></pre></div>
<p dir="auto"><strong>Actual behavior</strong></p>
<p dir="auto">Instead, the list of hashes is really small:</p>
<p dir="auto"><a target="_blank" rel="noopener noreferrer nofollow" href="https://user-images.githubusercontent.com/67953/51369662-44592980-1aa9-11e9-972d-e3650066213f.png"><img width="566" alt="screen shot 2019-01-17 at 10 42 58 pm" src="https://user-images.githubusercontent.com/67953/51369662-44592980-1aa9-11e9-972d-e3650066213f.png" style="max-width: 100%;"></a></p>
<p dir="auto"><strong>To Reproduce</strong></p>
<p dir="auto">Run <code class="notranslate">require('crypto').getHashes()</code> anywhere in your Electron app - you'll see that the available hashes is really small.</p>
<p dir="auto"><strong>Screenshots</strong><br>
See the one above.</p>
<p dir="auto"><strong>Additional Information</strong><br>
<code class="notranslate">ripemd160</code> specifically is very important to any cryptocurrency-related application, since RMD160 is used by Bitcoin-like chains to hash transaction data.</p>
<h3 dir="auto">Preflight Checklist</h3>
<p dir="auto">I have read the <a href="https://github.com/electron/electron/blob/master/CONTRIBUTING.md">Contributing Guidelines</a> for this project.<br>
I agree to follow the <a href="https://github.com/electron/electron/blob/master/CODE_OF_CONDUCT.md">Code of Conduct</a> that this project adheres to.<br>
I have searched the <a href="https://www.github.com/electron/electron/issues">issue tracker</a> for a feature request that matches the one I want to file, without success.</p>
<h3 dir="auto">Electron Version</h3>
<p dir="auto">11.3.0</p>
<h3 dir="auto">What operating system are you using?</h3>
<p dir="auto">macOS</p>
<h3 dir="auto">Operating System Version</h3>
<p dir="auto">macOS Catalina 10.15.7 and window 10 v2004</p>
<h3 dir="auto">What arch are you using?</h3>
<p dir="auto">x64</p>
<h3 dir="auto">Last Known Working Electron version</h3>
<p dir="auto">11.3.0</p>
<h3 dir="auto">Expected Behavior</h3>
<p dir="auto">Trigger print pdf by user button， round that the pdf (file has been downloaded locally) cannot be printed normally。Window and mac have the same problem， code show as below：</p>
<p dir="auto">export function printPage2(strUrl, isLocal = false, callback) {<br>
const printWindow = new BrowserWindow({<br>
title: 'Printer',<br>
show: true,<br>
width: 1024,<br>
height: 768,<br>
parent: tmpMinWindow,<br>
plugins: true,<br>
webPreferences: {<br>
devTools: false,<br>
nodeIntegration: true, //开启渲染进程中调用模块  即require<br>
enableRemoteModule: true,<br>
contextIsolation: false<br>
}<br>
})<br>
console.log('printPage2=' + strUrl)</p>
<p dir="auto">printWindow.loadFile(strUrl)</p>
<p dir="auto">// did-finish-load<br>
printWindow.webContents.on('did-finish-load', () =&gt; {<br>
console.log('did-finish-load')<br>
printWindow.webContents.print(<br>
{ silent: false, printBackground: false },<br>
(success, failureReason) =&gt; {<br>
console.log('success=' + success + ' failureReason =' + failureReason)<br>
if (callback) {<br>
callback(success ? null : failureReason)<br>
}<br>
}<br>
)<br>
})</p>
<p dir="auto">let sList = printWindow.webContents.getPrinters()<br>
console.log('sList = ' + JSON.stringify(sList))</p>
<p dir="auto">printWindow.webContents.on('did-fail-load', (event, errorCode, errorDes, validateURL) =&gt; {<br>
console.log('did-fail-load =' + errorCode)<br>
if (callback) {<br>
callback(errorDes)<br>
}<br>
})<br>
}</p>
<h3 dir="auto">Actual Behavior</h3>
<p dir="auto">BrowserWindow.webContents.print Unable to respond normally, no results are returned, one of the local printer jobs shows that the print job is being received, and there is no response on the printing side</p>
<h3 dir="auto">Testcase Gist URL</h3>
<p dir="auto"><em>No response</em></p>
<p dir="auto">Using pdf internal pdf printing can print normally, but it cannot work normally through BrowserWindow.webContents.print</p>