diff options
author | RaindropsSys <contact@minteck.org> | 2023-06-22 23:06:12 +0200 |
---|---|---|
committer | RaindropsSys <contact@minteck.org> | 2023-06-22 23:06:12 +0200 |
commit | 23563c7188e089929b60f9e10721c6fc43a220ff (patch) | |
tree | edfe2b009c82900d4ac27db02222d2f68dcad846 /includes/external/school/node_modules/node-forge/tests/nodejs-imap.js | |
parent | 7a7a49332df7c852abbaa33c7e8e87f93d064d61 (diff) | |
download | pluralconnect-23563c7188e089929b60f9e10721c6fc43a220ff.tar.gz pluralconnect-23563c7188e089929b60f9e10721c6fc43a220ff.tar.bz2 pluralconnect-23563c7188e089929b60f9e10721c6fc43a220ff.zip |
Updated 15 files, added includes/maintenance/deleteUnusedAssets.php and deleted 4944 files (automated)
Diffstat (limited to 'includes/external/school/node_modules/node-forge/tests/nodejs-imap.js')
-rw-r--r-- | includes/external/school/node_modules/node-forge/tests/nodejs-imap.js | 46 |
1 files changed, 0 insertions, 46 deletions
diff --git a/includes/external/school/node_modules/node-forge/tests/nodejs-imap.js b/includes/external/school/node_modules/node-forge/tests/nodejs-imap.js deleted file mode 100644 index ba024ef..0000000 --- a/includes/external/school/node_modules/node-forge/tests/nodejs-imap.js +++ /dev/null @@ -1,46 +0,0 @@ -var forge = require('../js/forge'); -var net = require('net'); - -var socket = new net.Socket(); - -var client = forge.tls.createConnection({ - server: false, - verify: function(connection, verified, depth, certs) { - // skip verification for testing - return true; - }, - connected: function(connection) { - console.log('[tls] connected'); - }, - tlsDataReady: function(connection) { - // encrypted data is ready to be sent to the server - var data = connection.tlsData.getBytes(); - socket.write(data, 'binary'); - }, - dataReady: function(connection) { - // clear data from the server is ready - var data = connection.data.getBytes(); - console.log('[tls] received from the server: ' + data); - client.close(); - }, - closed: function() { - console.log('[tls] disconnected'); - }, - error: function(connection, error) { - console.log('[tls] error', error); - } -}); - -socket.on('connect', function() { - console.log('[socket] connected'); - client.handshake(); -}); -socket.on('data', function(data) { - client.process(data.toString('binary')); -}); -socket.on('end', function() { - console.log('[socket] disconnected'); -}); - -// connect to gmail's imap server -socket.connect(993, 'imap.gmail.com'); |