This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* Custom PropType for checking multiple PropTypes. | |
* | |
* Returns an error if the prop does not pass one of the PropType checks. | |
* Sourced from: http://stackoverflow.com/a/31169012 | |
* | |
* @param {mixed} any valid React PropType (element|string|arrayOf|shape|...) | |
* | |
* @returns {error} returns an error if all fail | |
*/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(function () { | |
var body = document.getElementsByTagName('body')[0]; | |
body.addEventListener('animationend', handleAnimEnd); | |
var path = ''; | |
// fade in on dom load | |
(function (fn) { | |
if (document.readyState != 'loading') { | |
fn(); | |
} else { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
.fancydom-in { opacity: 0 !important; animation: fadeIn 0.5s linear forwards; } | |
.fancydom-out { opacity: 1; animation: fadeOut 0.25s linear forwards; } | |
@keyframes fadeIn { 0% { opacity: 0; visibility: visible; } | |
0.1% { opacity: 0; } | |
100% { opacity: 1; } } | |
@keyframes fadeOut { 0% { opacity: 1; } | |
99.9% { opacity: 0; } | |
100% { opacity: 0; visibility: hidden; } } |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// transmitter.js | |
const http = require('http'); | |
const fs = require('fs'); | |
const requestOpts = { | |
hostname: 'localhost', | |
port: 1337, | |
method: 'POST' | |
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const express = require('express'); | |
const app = express(); | |
const crypto = require('crypto'); | |
const supportedAlgos = new Set(['SHA1', 'SHA256', 'SHA512']); | |
app.use(express.static('./')); | |
app.get('/encrypt', (req, res) => { | |
const { algorithm, string } = req.query; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE html> | |
<html lang="en"> | |
<head> | |
<meta charset="UTF-8"> | |
<title>Encrypt</title> | |
</head> | |
<body> | |
<div> | |
<p>Text to encrypt:</p> | |
<input id="text" type="text" placeholder="Plain text here" /> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{"lastUpload":"2020-07-03T22:26:04.449Z","extensionVersion":"v3.4.3"} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const crypto = require('crypto'); | |
const fs = require('fs'); | |
const path = require('path'); | |
const zlib = require('zlib'); | |
const AppendInitVect = require('./appendInitVect'); | |
const getCipherKey = require('./getCipherKey'); | |
function encrypt({ file, password }) { | |
// Generate a secure, pseudo random initialization vector. |
OlderNewer