Skip to content

Commit 841e760

Browse files
committed
Merge remote-tracking branch 'upstream/master' into features/rsa
2 parents 31e758c + db232f4 commit 841e760

File tree

593 files changed

+53290
-8557
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

593 files changed

+53290
-8557
lines changed

.babelrc

-19
This file was deleted.

.editorconfig

+1-1
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,6 @@ trim_trailing_whitespace = true
99
indent_style = space
1010
indent_size = 4
1111

12-
[{package.json,.travis.yml}]
12+
[{package.json,.travis.yml,nightwatch.json}]
1313
indent_style = space
1414
indent_size = 2

.eslintignore

+1
Original file line numberDiff line numberDiff line change
@@ -1 +1,2 @@
11
src/core/vendor/**
2+
src/web/static/clippy_assets/**

.eslintrc.json

+17-5
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,12 @@
11
{
2+
"parser": "babel-eslint",
23
"parserOptions": {
34
"ecmaVersion": 9,
45
"ecmaFeatures": {
56
"impliedStrict": true
67
},
7-
"sourceType": "module"
8+
"sourceType": "module",
9+
"allowImportExportEverywhere": true
810
},
911
"env": {
1012
"browser": true,
@@ -36,9 +38,12 @@
3638

3739
// disable rules from base configurations
3840
"no-control-regex": "off",
41+
"require-atomic-updates": "off",
42+
"no-async-promise-executor": "off",
3943

4044
// stylistic conventions
4145
"brace-style": ["error", "1tbs"],
46+
"space-before-blocks": ["error", "always"],
4247
"block-spacing": "error",
4348
"array-bracket-spacing": "error",
4449
"comma-spacing": "error",
@@ -87,16 +92,23 @@
8792
"no-var": "error",
8893
"prefer-const": "error"
8994
},
95+
"overrides": [
96+
{
97+
"files": "tests/**/*",
98+
"rules": {
99+
"no-unused-expressions": "off",
100+
"no-console": "off"
101+
}
102+
}
103+
],
90104
"globals": {
91105
"$": false,
92106
"jQuery": false,
93107
"log": false,
108+
"app": false,
94109

95110
"COMPILE_TIME": false,
96111
"COMPILE_MSG": false,
97-
"PKG_VERSION": false,
98-
"ENVIRONMENT_IS_WORKER": false,
99-
"ENVIRONMENT_IS_NODE": false,
100-
"ENVIRONMENT_IS_WEB": false
112+
"PKG_VERSION": false
101113
}
102114
}

.github/CONTRIBUTING.md

+6-6
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ There are lots of opportunities to contribute to CyberChef. If you want ideas, t
66

77
Before your contributions can be accepted, you must:
88

9-
- Sign the [GCHQ Contributor Licence Agreement](https://github.com/gchq/Gaffer/wiki/GCHQ-OSS-Contributor-License-Agreement-V1.0)
9+
- Sign the [GCHQ Contributor Licence Agreement](https://cla-assistant.io/gchq/CyberChef)
1010
- Push your changes to your fork.
1111
- Submit a pull request.
1212

@@ -22,15 +22,15 @@ Before your contributions can be accepted, you must:
2222
* Line endings: UNIX style (\n)
2323

2424

25-
## Design Principals
25+
## Design Principles
2626

2727
1. If at all possible, all operations and features should be client-side and not rely on connections to an external server. This increases the utility of CyberChef on closed networks and in virtual machines that are not connected to the Internet. Calls to external APIs may be accepted if there is no other option, but not for critical components.
28-
2. Latency should be kept to a minimum to enhance the user experience. This means that all operation code should sit on the client, rather than being loaded dynamically from a server.
29-
3. Use Vanilla JS if at all possible to reduce the number of libraries required and relied upon. Frameworks like jQuery, although included, should not be used unless absolutely necessary.
30-
4. Minimise the use of large libraries, especially for niche operations that won't be used very often - these will be downloaded by everyone using the app, whether they use that operation or not (due to principal 2).
28+
2. Latency should be kept to a minimum to enhance the user experience. This means that operation code should sit on the client and be executed there. However, as a trade-off between latency and bandwidth, operation code with large dependencies can be loaded in discrete modules in order to reduce the size of the initial download. The downloading of additional modules must remain entirely transparent so that the user is not inconvenienced.
29+
3. Large libraries should be kept in separate modules so that they are not downloaded by everyone who uses the app, just those who specifically require the relevant operations.
30+
4. Use Vanilla JS if at all possible to reduce the number of libraries required and relied upon. Frameworks like jQuery, although included, should not be used unless absolutely necessary.
3131

3232

33-
With these principals in mind, any changes or additions to CyberChef should keep it:
33+
With these principles in mind, any changes or additions to CyberChef should keep it:
3434

3535
- Standalone
3636
- Efficient

.github/ISSUE_TEMPLATE.md

+1-14
Original file line numberDiff line numberDiff line change
@@ -1,14 +1 @@
1-
<!-- Prefix the title above with one of the following: -->
2-
<!-- Bug report: -->
3-
<!-- Operation request: -->
4-
<!-- Feature request: -->
5-
<!-- Misc: -->
6-
7-
### Summary
8-
9-
10-
### Example
11-
<!-- If describing a bug, tell us what happens instead of the expected behavior -->
12-
<!-- Include a link that triggers the bug if possible -->
13-
<!-- If you are requesting a new operation, include example input and output -->
14-
1+
<!-- Prefix the title above with 'Misc:' -->

.github/ISSUE_TEMPLATE/bug-report.md

+33
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,33 @@
1+
---
2+
name: Bug report
3+
about: Create a report to help us improve
4+
title: 'Bug report: <Insert title here>'
5+
labels: bug
6+
assignees: ''
7+
8+
---
9+
10+
**Describe the bug**
11+
A clear and concise description of what the bug is.
12+
13+
**To Reproduce**
14+
Steps to reproduce the behaviour or a link to the recipe / input used to cause the bug:
15+
16+
1. Go to '...'
17+
2. Click on '....'
18+
3. Scroll down to '....'
19+
4. See error
20+
21+
**Expected behaviour**
22+
A clear and concise description of what you expected to happen.
23+
24+
**Screenshots**
25+
If applicable, add screenshots to help explain your problem.
26+
27+
**Desktop (if relevant, please complete the following information):**
28+
- OS: [e.g. Windows]
29+
- Browser [e.g. chrome, safari]
30+
- Version [e.g. 22]
31+
32+
**Additional context**
33+
Add any other context about the problem here.

.github/ISSUE_TEMPLATE/bug_report.md

+34
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,34 @@
1+
---
2+
name: Bug report
3+
about: Create a report to help us improve
4+
title: 'Bug report: <Insert title here>'
5+
labels: bug
6+
assignees: ''
7+
8+
---
9+
10+
<!-- Prefix the title above with 'Bug report:' -->
11+
**Describe the bug**
12+
A clear and concise description of what the bug is.
13+
14+
**To Reproduce**
15+
Steps to reproduce the behavior or a link to the recipe / input used to cause the bug:
16+
17+
1. Go to '...'
18+
2. Click on '....'
19+
3. Scroll down to '....'
20+
4. See error
21+
22+
**Expected behavior**
23+
A clear and concise description of what you expected to happen.
24+
25+
**Screenshots**
26+
If applicable, add screenshots to help explain your problem.
27+
28+
**Desktop (if relevant, please complete the following information):**
29+
- OS: [e.g. Windows]
30+
- Browser [e.g. chrome, safari]
31+
- Version [e.g. 22]
32+
33+
**Additional context**
34+
Add any other context about the problem here.
+20
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
---
2+
name: Feature request
3+
about: Suggest an idea for the project
4+
title: 'Feature request: <Insert title here>'
5+
labels: feature
6+
assignees: ''
7+
8+
---
9+
10+
**Is your feature request related to a problem? Please describe.**
11+
A clear and concise description of what the problem is. E.g. I'm always frustrated when [...]
12+
13+
**Describe the solution you'd like**
14+
A clear and concise description of what you want to happen.
15+
16+
**Describe alternatives you've considered**
17+
A clear and concise description of any alternative solutions or features you've considered.
18+
19+
**Additional context**
20+
Add any other context or screenshots about the feature request here.
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
---
2+
name: Operation request
3+
about: Suggest a new operation
4+
title: 'Operation request: <Insert title here>'
5+
labels: operation
6+
assignees: ''
7+
8+
---
9+
10+
## Summary
11+
12+
### Example Input
13+
14+
### Example Output

.gitignore

+6-3
Original file line numberDiff line numberDiff line change
@@ -2,11 +2,14 @@ node_modules
22
npm-debug.log
33
travis.log
44
build
5-
docs/*
6-
!docs/*.conf.json
7-
!docs/*.ico
85
.vscode
6+
.*.swp
7+
.DS_Store
98
src/core/config/modules/*
109
src/core/config/OperationConfig.json
1110
src/core/operations/index.mjs
11+
src/node/config/OperationConfig.json
12+
src/node/index.mjs
13+
**/*.DS_Store
14+
tests/browser/output/*
1215

.npmignore

-1
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,5 @@ npm-debug.log
33
travis.log
44
build/*
55
!build/node
6-
docs
76
.vscode
87
.github

.travis.yml

+11-6
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,19 @@
11
language: node_js
22
node_js:
3-
- node
3+
- lts/*
4+
cache: npm
5+
addons:
6+
chrome: stable
47
install: npm install
58
before_script:
69
- npm install -g grunt
10+
- export NODE_OPTIONS=--max_old_space_size=2048
711
script:
812
- grunt lint
913
- grunt test
10-
- grunt docs
11-
- grunt node
14+
- grunt testnodeconsumer
1215
- grunt prod --msg="$COMPILE_MSG"
16+
- xvfb-run --server-args="-screen 0 1200x800x24" grunt testui
1317
before_deploy:
1418
- grunt exec:sitemap
1519
- grunt copy:ghPages
@@ -26,17 +30,18 @@ deploy:
2630
skip_cleanup: true
2731
api_key:
2832
secure: "HV1WSKv4l/0Y2bKKs1iBJocBcmLj08PCRUeEM/jTwA4jqJ8EiLHWiXtER/D5sEg2iibRVKd2OQjfrmS6bo4AiwdeVgAKmv0FtS2Jw+391N8Nd5AkEANHa5Om/IpHLTL2YRAjpJTsDpY72bMUTJIwjQA3TFJkgrpOw6KYfohOcgbxLpZ4XuNJRU3VL4Hsxdv5V9aOVmfFOmMOVPQlakXy7NgtW5POp1f2WJwgcZxylkR1CjwaqMyXmSoVl46pyH3tr5+dptsQoKSGdi6sIHGA60oDotFPcm+0ifa47wZw+vapuuDi4tdNxhrHGaDMG8xiE0WFDHwQUDlk2/+W7j9SEX0H3Em7us371JXRp56EDwEcDa34VpVkC6i8HGcHK55hnxVbMZXGf3qhOFD8wY7qMbjMRvIpucrMHBi86OfkDfv0vDj2LyvIl5APj/AX50BrE0tfH1MZbH26Jkx4NdlkcxQ14GumarmUqfmVvbX/fsoA6oUuAAE9ZgRRi3KHO4wci6KUcRfdm+XOeUkaBFsL86G3EEYIvrtBTuaypdz+Cx7nd1iPZyWMx5Y1gXnVzha4nBdV4+7l9JIsFggD8QVpw2uHXQiS1KXFjOeqA3DBD8tjMB7q26Fl2fD3jkOo4BTbQ2NrRIZUu/iL+fOmMPsyMt2qulB0yaSBCfkbEq8xrUA="
33+
file_glob: true
2934
file:
30-
- build/prod/cyberchef.htm
31-
- build/node/CyberChef.js
35+
- build/prod/*.zip
36+
- src/node/cjs.js
3237
on:
3338
repo: gchq/CyberChef
3439
tags: true
3540
- provider: npm
3641
skip_cleanup: true
3742
email: "n1474335@gmail.com"
3843
api_key:
39-
secure: "Z3FK6bm4RfQEIRXZ1lBNzQkVIoHpivThr9U+XBHmsBgIfdrK/XUnzs/slugo+NIz8nPiGmMx4gxyJonBCLHDGb1ysky2aEWTl26c0teaF4DeQEjWC1ZaGzv8MV1/GkUamnr1qouXjyUhyEAp33rd8ccN9Rq3QNYB/qLDcA9/FCme7JCW6sCd4zWO0LGEYMJEMc2FzAUkqhqsI05hegGhSDgKXRn5PmLARek4yHD+Hx7pstaTeQIy0WoGJjdzoB3iJIMmo/hWZGzZafktUOh223c5qzx4zMpDRNmMngBUw6R94nKd4KvplYRgB87Y3L/aiVU4CF+axwLmK8RPaC1wbJnlHf06zxHPdiFmsY/zKPpNel+nOnxzRrF5l2KMU4TU6gug3s9Jnzp9T5UMfhp0jW3YkxHGeuOPOeE1i0lTUWUGWrPHLQquAhLfkr2zxaU4ETk/y85hq9W4LAy0ENEDVXX2jP7FnI4Z1fdpmljpmVNJR+outPg6t+Coqgvil7v7XpMtDm8lKQanVYuxwmkb/ncOWFRWuM2j5zIEg3CHnFDcJ9bYrfKRg0b0tb/2BWD14pQnV76goVwzJQYVzdPc8TKIYJw2BZ1Nh9c0iruQVebe/6l1FX9fDCkz8VMmltni61/LxZrf8y0NT1YaU1raeNY2dH5UWvEa9p72FPMI6Eg="
44+
secure: "UnDQL3Kh+GK2toL0TK3FObO0ujVssU3Eg4BBuYdjwLB81GhiGE5/DTh7THdZPOpbLo6wQeOwfZDuMeKC1OU+0Uf4NsdYFu1aq6xMO20qBQ4qUfgsyiK4Qgywj9gk0p1+OFZdGAZ/j1CNRAaF71XQIY6iV84c+SO4WoizXYrNT0Jh4sr2DA4/97G2xmJtPi0qOzYrJ09R56ZUozmqeik5G0pMRIuJRbpjS/7bZXV+N7WV0ombZc9RkUaetbabEVOLQ+Xx5YAIVq+VuEeMe9VBSnxY/FfCLmy1wJsjGzpLCyBI9nbrG4nw8Wgc2m8NfK9rcpIvBTGner9r2j60NVDkZ8kLZPrqXhq6AZMwa+oz6K5UQCqRo2RRQzSGwXxg67HY5Tcq+oNmjd+DqpPg4LZ3eGlluyP5XfG+hpSr9Ya4d8q8SrUWLxkoLHI6ZKMtoKFbTCSSQPiluW5hsZxjz3yDkkjsJw64M/EM8UyJrgaXqDklQu+7rBGKLfsK6os7RDiqjBWpQ7gwpo8HvY0O8yqEAabPz+QGkanpjcCOZCXFbSkzWxYy37RMAPu88iINVZVlZE4l+WJenCpZY95ueyy0mG9cyMSzVRPyX6A+/n4H6VMFPFjpGDLTD588ACEjY1lmHfS/eXwXJcgqPPD2gW0XdRdUheU/ssqlfCfGWQMTDXs="
4045
on:
4146
tags: true
4247
branch: master

0 commit comments

Comments
 (0)