├── .babelrc ├── .editorconfig ├── .eslintrc.yml ├── .gitattributes ├── .gitignore ├── .nvmrc ├── .stylelintrc ├── CODE_OF_CONDUCT.md ├── LICENSE ├── README.md ├── app ├── AC │ ├── cloudCspActions.ts │ ├── documentsActions.ts │ ├── documentsFiltersActions.ts │ ├── eventsActions.ts │ ├── eventsFiltersActions.ts │ ├── index.ts │ ├── megafonActions.ts │ ├── searchActions.ts │ └── servicesActions.ts ├── Filters │ └── SearchElement.tsx ├── app.global.css ├── app.html ├── app.tsx ├── components │ ├── About │ │ ├── AboutWindow.tsx │ │ ├── FeedbackForm.tsx │ │ └── ProductInformation.tsx │ ├── App.tsx │ ├── BlockNotElements.tsx │ ├── CRL │ │ ├── CRLDelete.tsx │ │ ├── CRLExport.tsx │ │ ├── CRLInfo.tsx │ │ ├── CRLList.tsx │ │ └── CRLListItem.tsx │ ├── Certificate │ │ ├── CertificateBlockForEncrypt.tsx │ │ ├── CertificateBlockForSignature.tsx │ │ ├── CertificateChainInfo.tsx │ │ ├── CertificateDelete.tsx │ │ ├── CertificateExport.tsx │ │ ├── CertificateInfo.tsx │ │ ├── CertificateInfoTabs.tsx │ │ ├── CertificateList.tsx │ │ ├── CertificateListItem.tsx │ │ └── CertificateWindow.tsx │ ├── CheckBoxWithLabel.tsx │ ├── CloudCSP │ │ ├── AuthWebView.tsx │ │ └── CloudCSP.tsx │ ├── Containers │ │ ├── ContainerListItem.tsx │ │ ├── ContainersList.tsx │ │ └── ContainersWindow.tsx │ ├── DatePicker.tsx │ ├── Diagnostic │ │ ├── Diagnostic.tsx │ │ ├── DiagnosticModal.tsx │ │ ├── Problems.tsx │ │ └── Resolve.tsx │ ├── Dialog.tsx │ ├── Documents │ │ ├── DeleteDocuments.tsx │ │ ├── DocumentsTable.tsx │ │ ├── DocumentsWindow.tsx │ │ └── FilterDocuments.tsx │ ├── EncodingTypeSelector.tsx │ ├── Encrypt │ │ ├── EncryptButtons.tsx │ │ ├── EncryptSettings.tsx │ │ └── EncryptWindow.tsx │ ├── Events │ │ ├── EventTable.tsx │ │ ├── EventsWindow.tsx │ │ └── FilterEvents.tsx │ ├── Files │ │ ├── FileIcon.tsx │ │ ├── FileList.tsx │ │ ├── FileListItem.tsx │ │ ├── FileSelector.tsx │ │ ├── RemoteFileListItem.tsx │ │ └── fileManager.ts │ ├── Footer.tsx │ ├── HeaderWorkspaceBlock.tsx │ ├── Help │ │ └── HelpWindow.tsx │ ├── LocaleSelect.tsx │ ├── MainWindow │ │ ├── MainWindow.tsx │ │ └── MainWindowOperation.tsx │ ├── MenuBar.tsx │ ├── Modal.tsx │ ├── PasswordDialog.tsx │ ├── ProgressBars.tsx │ ├── RecipientsList.tsx │ ├── Request │ │ ├── CertificateRequest.tsx │ │ ├── HeaderTabs.tsx │ │ ├── KeyParameters.tsx │ │ ├── RequestButtons.tsx │ │ └── SubjectNameInfo.tsx │ ├── Root.tsx │ ├── SelectFolder.tsx │ ├── Services │ │ ├── AddService.tsx │ │ ├── CryptoProDssSettings.tsx │ │ ├── CryptoProSVSSettings.tsx │ │ ├── DeleteService.tsx │ │ ├── MegafonSettings.tsx │ │ ├── ModifyService.tsx │ │ ├── PinCodeForDssContainer.tsx │ │ ├── ServiceCertificates.tsx │ │ ├── ServiceIcon.tsx │ │ ├── ServiceInfo.tsx │ │ ├── ServicesList.tsx │ │ ├── ServicesListItem.tsx │ │ ├── ServicesWindow.tsx │ │ ├── TextForShowOnMobilePhone.tsx │ │ └── types.ts │ ├── SideMenu.tsx │ ├── Signature │ │ ├── SignatureButtons.tsx │ │ ├── SignatureInfoBlock.tsx │ │ ├── SignatureSettings.tsx │ │ ├── SignatureStatus.tsx │ │ └── SignatureWindow.tsx │ ├── SignatureSettings.tsx.bak │ ├── SignatureWindow.tsx.bak │ ├── SignerCertificateInfo.tsx │ ├── Sort │ │ ├── SortDirection.ts │ │ └── SortIndicator.tsx │ ├── ToolBarForEncryptCertificateBlock.tsx │ └── ToolBarWithSearch.tsx ├── constants.ts ├── decorators │ └── accordion.tsx ├── errors.ts ├── history.ts ├── i18n │ ├── EN.ts │ ├── RU.ts │ └── localize.tsx ├── index.d.ts ├── main.development.js ├── menu.js ├── middlewares │ ├── logger.ts │ └── randomId.ts ├── package-lock.json ├── package.json ├── reducer │ ├── certificates.ts │ ├── cloudCSP.ts │ ├── connections.ts │ ├── containers.ts │ ├── crls.ts │ ├── documents.ts │ ├── events.ts │ ├── files.ts │ ├── filters.ts │ ├── index.ts │ ├── megafon.ts │ ├── recipients.ts │ ├── remoteFiles.ts │ ├── services.ts │ ├── settings.ts │ ├── signatures.ts │ └── signers.ts ├── resources │ ├── agreement.html │ ├── cryptoarm-gost.icns │ ├── cryptoarm-gost.ico │ ├── cryptoarm-gost.png │ ├── cryptoarm-gost_1024.png │ ├── css │ │ ├── font-awesome-animation.min.css │ │ ├── materialize.css │ │ ├── materialize.min.css │ │ ├── nouislider.css │ │ └── react-virtualized.css │ ├── fonts │ │ ├── material-design-icons │ │ │ ├── MaterialIcons-Regular.eot │ │ │ ├── MaterialIcons-Regular.ijmap │ │ │ ├── MaterialIcons-Regular.svg │ │ │ ├── MaterialIcons-Regular.ttf │ │ │ ├── MaterialIcons-Regular.woff │ │ │ ├── MaterialIcons-Regular.woff2 │ │ │ ├── README.md │ │ │ ├── codepoints │ │ │ └── material-icons.css │ │ └── roboto │ │ │ ├── Roboto-Bold.eot │ │ │ ├── Roboto-Bold.ttf │ │ │ ├── Roboto-Bold.woff │ │ │ ├── Roboto-Bold.woff2 │ │ │ ├── Roboto-Light.eot │ │ │ ├── Roboto-Light.ttf │ │ │ ├── Roboto-Light.woff │ │ │ ├── Roboto-Light.woff2 │ │ │ ├── Roboto-Medium.eot │ │ │ ├── Roboto-Medium.ttf │ │ │ ├── Roboto-Medium.woff │ │ │ ├── Roboto-Medium.woff2 │ │ │ ├── Roboto-Regular.eot │ │ │ ├── Roboto-Regular.ttf │ │ │ ├── Roboto-Regular.woff │ │ │ ├── Roboto-Regular.woff2 │ │ │ ├── Roboto-Thin.eot │ │ │ ├── Roboto-Thin.ttf │ │ │ ├── Roboto-Thin.woff │ │ │ └── Roboto-Thin.woff2 │ ├── image │ │ ├── A43AE36C.png │ │ ├── Flag_of_Russia.png │ │ ├── Flag_of_United_States.png │ │ ├── about_menu_icon.svg │ │ ├── address_contact_icon.png │ │ ├── agreement_menu_icon.svg │ │ ├── alert_error_icon.svg │ │ ├── alert_ok_icon.svg │ │ ├── alert_warning_icon.svg │ │ ├── bug.svg │ │ ├── cert_category_intermediate.svg │ │ ├── cert_category_my.svg │ │ ├── cert_category_other.svg │ │ ├── cert_category_request.svg │ │ ├── cert_category_root.svg │ │ ├── cert_category_token.svg │ │ ├── cert_error.svg │ │ ├── cert_menu_icon.svg │ │ ├── cert_menu_icon_white.svg │ │ ├── cert_ok.svg │ │ ├── cert_roundbutton_icon.svg │ │ ├── cert_roundbutton_over_icon.svg │ │ ├── cert_status_error.svg │ │ ├── cert_status_ok.svg │ │ ├── chain_1.png │ │ ├── chain_10.png │ │ ├── chain_2.png │ │ ├── chain_3.png │ │ ├── chain_4.png │ │ ├── chain_5.png │ │ ├── chain_6.png │ │ ├── chain_7.png │ │ ├── chain_8.png │ │ ├── chain_9.png │ │ ├── connect.png │ │ ├── cryptoarm-gost.png │ │ ├── cryptoarm-gost.svg │ │ ├── docmenu_arhiver.svg │ │ ├── docmenu_decrypt.svg │ │ ├── docmenu_encrypt.svg │ │ ├── docmenu_remove.svg │ │ ├── docmenu_removesign.svg │ │ ├── docmenu_sign.svg │ │ ├── docmenu_verifysign.svg │ │ ├── document_menu_icon.svg │ │ ├── dss_menu_icon.svg │ │ ├── encrypt_menu_icon.svg │ │ ├── encrypt_roundbutton_icon.svg │ │ ├── encrypt_roundbutton_over_icon.svg │ │ ├── encrypt_type_icon.png │ │ ├── encrypt_type_icon.svg │ │ ├── excel_type_icon.png │ │ ├── excel_type_icon.svg │ │ ├── exit_menu_icon.svg │ │ ├── facebook_icon.svg │ │ ├── file_type_icon.png │ │ ├── file_type_icon.svg │ │ ├── files │ │ │ ├── file_avi.png │ │ │ ├── file_csr.png │ │ │ ├── file_doc.png │ │ │ ├── file_docx.png │ │ │ ├── file_enc.png │ │ │ ├── file_file.png │ │ │ ├── file_jpg.png │ │ │ ├── file_pdf.png │ │ │ ├── file_pfx.png │ │ │ ├── file_ppt.png │ │ │ ├── file_sig.png │ │ │ ├── file_sig_any.png │ │ │ ├── file_sig_error.png │ │ │ ├── file_sig_ok.png │ │ │ ├── file_txt.png │ │ │ ├── file_unknown.png │ │ │ ├── file_xls.png │ │ │ └── file_zip.png │ │ ├── folder_shoose_icon.svg │ │ ├── geo_contact_icon.png │ │ ├── geo_gray.png │ │ ├── google_icon.svg │ │ ├── help │ │ │ ├── cert_windows_chain.png │ │ │ ├── cert_windows_using.png │ │ │ ├── decrypt_window.png │ │ │ ├── encrypt_window_choose_cert.png │ │ │ ├── encrypt_window_choose_files.png │ │ │ ├── encrypt_window_clear.png │ │ │ ├── license_window.png │ │ │ ├── license_window_modal.png │ │ │ ├── main_window.png │ │ │ ├── main_window_menu.png │ │ │ ├── menu_button.png │ │ │ ├── sign_window_choose_cert.png │ │ │ ├── sign_window_clear.png │ │ │ ├── sign_window_filling.png │ │ │ ├── sign_window_verify.png │ │ │ └── user_guide.png │ │ ├── help_menu_icon.svg │ │ ├── icon_context_menu.svg │ │ ├── icon_fail.svg │ │ ├── icon_filter_off.svg │ │ ├── icon_filter_on.svg │ │ ├── icon_ok.svg │ │ ├── journal_menu_icon.svg │ │ ├── key.svg │ │ ├── key_container_icon.png │ │ ├── key_store_menu_icon.svg │ │ ├── left-arrow.svg │ │ ├── licence_footer.png │ │ ├── license_menu_icon.svg │ │ ├── login-password.svg │ │ ├── logo_ct.svg │ │ ├── logo_ct.svg_ │ │ ├── logo_trusted.png │ │ ├── logo_trusted.svg │ │ ├── mail_contact_icon.png │ │ ├── mail_icon.svg │ │ ├── main.png │ │ ├── main_window_header.png │ │ ├── operation_status_error.svg │ │ ├── operation_status_success.svg │ │ ├── password.svg │ │ ├── pdf_type_icon.png │ │ ├── pdf_type_icon.svg │ │ ├── preloader.png │ │ ├── preloader.psd │ │ ├── return-button.svg │ │ ├── service_category_cert.svg │ │ ├── service_category_connect.svg │ │ ├── services │ │ │ ├── dss.png │ │ │ ├── dss_key.svg │ │ │ ├── megafon.png │ │ │ └── svs.png │ │ ├── sign_menu_icon.png │ │ ├── sign_menu_icon.svg │ │ ├── sign_roundbutton_icon.svg │ │ ├── sign_roundbutton_over_icon.svg │ │ ├── sign_type_icon.png │ │ ├── sign_type_icon.svg │ │ ├── social-media-campaign.svg │ │ ├── status_cert_fail_icon.svg │ │ ├── status_cert_ok_icon.svg │ │ ├── target.svg │ │ ├── tray.ico │ │ ├── tray.png │ │ ├── tray_mac.png │ │ ├── tray_nix.png │ │ ├── tree_element.svg │ │ ├── trusted-esign.png │ │ ├── trusted-esign.svg │ │ ├── twitter_icon.svg │ │ ├── vk_icon.svg │ │ ├── warning.svg │ │ ├── word_type_icon.png │ │ ├── word_type_icon.svg │ │ ├── zip_type_icon.png │ │ └── zip_type_icon.svg │ ├── index.html │ ├── js │ │ ├── hammer.min.js │ │ ├── jquery-3.2.1.min.js │ │ ├── jquery.visible.js │ │ ├── jquery.visible.min.js │ │ ├── materialize.js │ │ ├── materialize.min.js │ │ └── nouislider.js │ ├── language │ │ ├── EN.json │ │ └── RU.json │ ├── preloader_index.html │ └── ssl │ │ ├── addCA.linux.sh │ │ ├── addCA.osx.sh │ │ ├── addCA.win.bat │ │ ├── cert.pem │ │ ├── certutil │ │ ├── osx │ │ │ ├── certutil │ │ │ ├── libfreebl3.dylib │ │ │ ├── libgtest1.dylib │ │ │ ├── libgtestutil.dylib │ │ │ ├── libnspr4.dylib │ │ │ ├── libnss3.dylib │ │ │ ├── libnssckbi.dylib │ │ │ ├── libnssdbm3.dylib │ │ │ ├── libnssutil3.dylib │ │ │ ├── libplc4.dylib │ │ │ ├── libplds4.dylib │ │ │ ├── libsmime3.dylib │ │ │ ├── libsoftokn3.dylib │ │ │ ├── libssl3.dylib │ │ │ └── new_card.tmpl │ │ └── win32 │ │ │ ├── certutil.exe │ │ │ ├── freebl3.dll │ │ │ ├── libnspr4.dll │ │ │ ├── libplc4.dll │ │ │ ├── libplds4.dll │ │ │ ├── nss3.dll │ │ │ ├── nssckbi.dll │ │ │ ├── nssdbm3.dll │ │ │ ├── nssutil3.dll │ │ │ ├── smime3.dll │ │ │ ├── softokn3.dll │ │ │ ├── sqlite3.dll │ │ │ └── ssl3.dll │ │ ├── firefox │ │ ├── esign-firefox-preferences.cfg │ │ └── esign-firefox-preferences.js │ │ ├── key.pem │ │ ├── osx_firefox.sh │ │ └── root.pem ├── selectors │ ├── crlsSelectors.ts │ ├── documentsSelector.ts │ ├── eventsSelectors.ts │ └── index.ts ├── server │ ├── constants.ts │ ├── http.ts │ ├── https.ts │ ├── socketIO.ts │ └── socketManager.ts ├── service │ └── megafon │ │ ├── constants.ts │ │ ├── endpoint │ │ ├── sign.ts │ │ └── status.ts │ │ ├── statusCodes.ts │ │ └── types.ts ├── store │ ├── configureStore.development.ts │ ├── configureStore.production.ts │ ├── index.ts │ └── preloadedState.ts ├── table.global.css ├── trusted │ ├── encrypt.ts │ ├── sign.ts │ └── store.ts ├── utils.ts └── winstonLogger.ts ├── demo └── demo-socket.io │ ├── .gitignore │ ├── client │ ├── index.html │ └── src │ │ └── app.js │ ├── gulpfile.js │ ├── package-lock.json │ ├── package.json │ ├── readme.md │ ├── resources │ ├── file1.txt │ ├── file2.txt │ ├── file3.txt │ ├── file4.sig │ ├── file5.enc │ └── file7.pdf │ ├── server.js │ └── ssl │ ├── cert.pem │ └── key.pem ├── docs ├── Руководство пользователя.pdf └── Руководство программиста.pdf ├── package-lock.json ├── package.json ├── product.json ├── shrinkwrap.json ├── tsconfig.json ├── tslint.json ├── types ├── crypto.d.ts └── modal.d.ts ├── webpack.config.base.js ├── webpack.config.eslint.js ├── webpack.config.main.prod.js ├── webpack.config.renderer.dev.dll.js ├── webpack.config.renderer.dev.js └── webpack.config.renderer.prod.js /.babelrc: -------------------------------------------------------------------------------- 1 | { 2 | "presets": [ 3 | [ 4 | "env", 5 | { 6 | "targets": { 7 | "node": 6 8 | }, 9 | "useBuiltIns": true 10 | } 11 | ], 12 | "stage-0", 13 | "es2015", 14 | "react" 15 | ], 16 | "plugins": [ 17 | "add-module-exports", 18 | "dynamic-import-webpack" 19 | ], 20 | "env": { 21 | "production": { 22 | "presets": [ 23 | "react-optimize" 24 | ], 25 | "plugins": [ 26 | "transform-class-properties", 27 | "transform-es2015-classes", 28 | "babel-plugin-dev-expression" 29 | ] 30 | }, 31 | "development": { 32 | "presets": [ 33 | "react-hmre" 34 | ], 35 | "plugins": [ 36 | "transform-class-properties", 37 | "transform-es2015-classes", 38 | "react-hot-loader/babel" 39 | ] 40 | } 41 | } 42 | } 43 | -------------------------------------------------------------------------------- /.editorconfig: -------------------------------------------------------------------------------- 1 | root = true 2 | 3 | [*] 4 | indent_style = tab 5 | end_of_line = lf 6 | charset = utf-8 7 | trim_trailing_whitespace = true 8 | insert_final_newline = true 9 | 10 | [*.{json,js,jsx,ts,tsx,html,css}] 11 | indent_style = space 12 | indent_size = 2 13 | 14 | [.eslintrc] 15 | indent_style = space 16 | indent_size = 2 17 | 18 | [*.md] 19 | trim_trailing_whitespace = false 20 | -------------------------------------------------------------------------------- /.gitattributes: -------------------------------------------------------------------------------- 1 | * text eol=lf 2 | *.jpg binary 3 | *.png binary 4 | *.ico binary 5 | *.icns binary 6 | *.eot binary 7 | *.ttf binary 8 | *.woff binary 9 | *.woff2 binary 10 | *.exe binary 11 | *.dll binary 12 | *.dylib binary 13 | *.pdf binary 14 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | # Media files 2 | *.ai 3 | 4 | # Logs 5 | logs 6 | *.log 7 | 8 | # Runtime data 9 | pids 10 | *.pid 11 | *.seed 12 | 13 | # Directory for instrumented libs generated by jscoverage/JSCover 14 | lib-cov 15 | 16 | # Coverage directory used by tools like istanbul 17 | coverage 18 | 19 | # Grunt intermediate storage (http://gruntjs.com/creating-plugins#storing-task-files) 20 | .grunt 21 | 22 | # node-waf configuration 23 | .lock-wscript 24 | 25 | # Compiled binary addons (http://nodejs.org/api/addons.html) 26 | build/Release 27 | .eslintcache 28 | 29 | # Dependency directory 30 | # https://www.npmjs.org/doc/misc/npm-faq.html#should-i-check-my-node_modules-folder-into-git 31 | node_modules 32 | app/node_modules 33 | 34 | # OSX 35 | .DS_Store 36 | 37 | # App packaged 38 | release 39 | app/main.js 40 | app/main.js.map 41 | app/bundle.js 42 | app/bundle.js.map 43 | app/main.css 44 | app/main.css.map 45 | dist 46 | dll 47 | main.js 48 | main.js.map 49 | tmp 50 | tmp_app_build 51 | cache 52 | 53 | .idea 54 | npm-debug.log.* 55 | __snapshots__ 56 | .awcache 57 | 58 | /.vscode/ 59 | -------------------------------------------------------------------------------- /.nvmrc: -------------------------------------------------------------------------------- 1 | v6.9.5 2 | -------------------------------------------------------------------------------- /.stylelintrc: -------------------------------------------------------------------------------- 1 | { 2 | "extends": "stylelint-config-standard" 3 | } 4 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # Trusted eSign 2 |

3 | Trusted eSign in action 4 |

5 | 6 | ## Install dependencies 7 | 8 | ``` 9 | > npm install -g typescript 10 | > npm install 11 | 12 | ``` 13 | 14 | ## Build for dev 15 | ⚠️ Before run dev need manualy add trusted-crypto in /app/node_modules/ Will fixed in future 16 | ```bash 17 | git clone https://github.com/TrustedPlus/esign.git 18 | cd esign && npm install 19 | cd app && npm install 20 | cd .. 21 | npm run dev 22 | 23 | # Run tslint 24 | yarn lint 25 | ``` 26 | 27 | **NOTE:** 28 | * on Windows need have openssl [prebuild binaries](https://wiki.openssl.org/index.php/Binaries) or build from [sources](https://github.com/openssl/openssl/tree/OpenSSL_1_0_2k) in first time (for [trusted-crypto](https://github.com/TrustedPlus/crypto/blob/master/binding.gyp#L57)) 29 | * on Linux install openssl devel package 30 | -------------------------------------------------------------------------------- /app/AC/documentsFiltersActions.ts: -------------------------------------------------------------------------------- 1 | import { APPLY_DOCUMENTS_FILTERS, RESET_DOCUMENTS_FILTERS } from "../constants"; 2 | 3 | export function applyDocumentsFilters(filters: any) { 4 | return { 5 | payload: { filters }, 6 | type: APPLY_DOCUMENTS_FILTERS, 7 | }; 8 | } 9 | 10 | export function resetDocumentsFilters() { 11 | return { 12 | type: RESET_DOCUMENTS_FILTERS, 13 | }; 14 | } 15 | -------------------------------------------------------------------------------- /app/AC/eventsFiltersActions.ts: -------------------------------------------------------------------------------- 1 | import { 2 | APPLY_EVENTS_FILTERS, EVENTS_CHANGE_FILTER_DATE_FROM, EVENTS_CHANGE_FILTER_DATE_TO, 3 | EVENTS_CHANGE_FILTER_IN_OPERATION_OBJECT, EVENTS_CHANGE_FILTER_LEVEL, EVENTS_CHANGE_FILTER_OPERATION_TYPE, 4 | EVENTS_CHANGE_FILTER_OUT_OPERATION_OBJECT, EVENTS_CHANGE_FILTER_USER_NAME, RESET_EVENTS_FILTERS, 5 | } from "../constants"; 6 | 7 | export function changeFilterUserName(userName: string) { 8 | return { 9 | payload: { userName }, 10 | type: EVENTS_CHANGE_FILTER_USER_NAME, 11 | }; 12 | } 13 | 14 | export function changeFilterInObject(operationObjectIn: string) { 15 | return { 16 | payload: { operationObjectIn }, 17 | type: EVENTS_CHANGE_FILTER_IN_OPERATION_OBJECT, 18 | }; 19 | } 20 | 21 | export function changeFilterOutObject(operationObjectOut: string) { 22 | return { 23 | payload: { operationObjectOut }, 24 | type: EVENTS_CHANGE_FILTER_OUT_OPERATION_OBJECT, 25 | }; 26 | } 27 | 28 | export function changeFilterDateFrom(dateFrom: Date | undefined) { 29 | return { 30 | payload: { dateFrom }, 31 | type: EVENTS_CHANGE_FILTER_DATE_FROM, 32 | }; 33 | } 34 | 35 | export function changeFilterDateTo(dateTo: Date | undefined) { 36 | return { 37 | payload: { dateTo }, 38 | type: EVENTS_CHANGE_FILTER_DATE_TO, 39 | }; 40 | } 41 | 42 | export function changeFilterOperationsType(type: string, value: boolean) { 43 | return { 44 | payload: { type, value }, 45 | type: EVENTS_CHANGE_FILTER_OPERATION_TYPE, 46 | }; 47 | } 48 | 49 | export function changeFilterLevel(level: string) { 50 | return { 51 | payload: { level }, 52 | type: EVENTS_CHANGE_FILTER_LEVEL, 53 | }; 54 | } 55 | 56 | export function applyEventsFilters(filters: any) { 57 | return { 58 | payload: { filters }, 59 | type: APPLY_EVENTS_FILTERS, 60 | }; 61 | } 62 | 63 | export function resetEventsFilters() { 64 | return { 65 | type: RESET_EVENTS_FILTERS, 66 | }; 67 | } 68 | -------------------------------------------------------------------------------- /app/AC/searchActions.ts: -------------------------------------------------------------------------------- 1 | import { CHANGE_SEARCH_VALUE } from "../constants"; 2 | 3 | export function changeSearchValue(searchValue: string) { 4 | return { 5 | payload: { searchValue }, 6 | type: CHANGE_SEARCH_VALUE, 7 | }; 8 | } 9 | -------------------------------------------------------------------------------- /app/Filters/SearchElement.tsx: -------------------------------------------------------------------------------- 1 | import React from "react"; 2 | import { connect } from "react-redux"; 3 | import { changeSearchValue } from "../AC/searchActions"; 4 | 5 | interface ISearchElementState { 6 | open: boolean; 7 | } 8 | 9 | interface ISearchElementProps { 10 | changeSearchValue: (ev: any) => void; 11 | searchValue: string; 12 | } 13 | 14 | class SearchElement extends React.Component { 15 | constructor(props: ISearchElementProps) { 16 | super(props); 17 | 18 | this.state = ({ 19 | open: false, 20 | }); 21 | } 22 | 23 | handleOpen() { 24 | this.setState({ 25 | open: true, 26 | }); 27 | } 28 | 29 | handleClose() { 30 | // tslint:disable-next-line:no-shadowed-variable 31 | const { changeSearchValue } = this.props; 32 | 33 | changeSearchValue(""); 34 | 35 | this.setState({ 36 | open: false, 37 | }); 38 | } 39 | 40 | handleValueChange = (ev: any) => { 41 | // tslint:disable-next-line:no-shadowed-variable 42 | const { changeSearchValue } = this.props; 43 | changeSearchValue(ev.target.value); 44 | } 45 | 46 | render() { 47 | const { searchValue } = this.props; 48 | 49 | let mainClassName: string; 50 | 51 | this.state.open || searchValue.length ? mainClassName = "active" : mainClassName = ""; 52 | 53 | return ( 54 |
55 | 56 | search 57 | 58 |
59 | 60 | 61 | close 62 | 63 |
64 |
65 | ); 66 | } 67 | } 68 | 69 | export default connect((state) => ({ 70 | searchValue: state.filters.searchValue, 71 | }), { changeSearchValue })(SearchElement); 72 | -------------------------------------------------------------------------------- /app/app.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | Hello Electron React! 6 | 17 | 18 | 19 |
20 | 45 | 46 | 47 | -------------------------------------------------------------------------------- /app/app.tsx: -------------------------------------------------------------------------------- 1 | import * as React from "react"; 2 | import ReactDOM from "react-dom"; 3 | import "./app.global.css"; 4 | import Root from "./components/Root"; 5 | import store from "./store/index"; 6 | 7 | ReactDOM.render(, document.getElementById("container")); 8 | -------------------------------------------------------------------------------- /app/components/About/AboutWindow.tsx: -------------------------------------------------------------------------------- 1 | import React from "react"; 2 | import FeedbackForm from "./FeedbackForm"; 3 | import ProductInformation from "./ProductInformation"; 4 | 5 | class AboutWindow extends React.PureComponent { 6 | 7 | render() { 8 | return ( 9 | 10 |
11 |
12 |
13 |
14 | 15 |
16 |
17 | 18 |
19 |
20 |
21 |
22 |
23 | ); 24 | } 25 | } 26 | 27 | export default AboutWindow; 28 | -------------------------------------------------------------------------------- /app/components/BlockNotElements.tsx: -------------------------------------------------------------------------------- 1 | import React from "react"; 2 | 3 | interface IBlockNotElementsProps { 4 | name: string; 5 | title: string; 6 | } 7 | 8 | class BlockNotElements extends React.Component { 9 | render() { 10 | const { name, title } = this.props; 11 | return ( 12 |
13 |
{title}
14 | block 15 |
16 | ); 17 | } 18 | } 19 | 20 | export default BlockNotElements; 21 | -------------------------------------------------------------------------------- /app/components/CRL/CRLListItem.tsx: -------------------------------------------------------------------------------- 1 | import PropTypes from "prop-types"; 2 | import React from "react"; 3 | 4 | const rectangleValidStyle = { 5 | background: "#4caf50", 6 | }; 7 | 8 | const rectangleUnvalidStyle = { 9 | background: "#bf3817", 10 | }; 11 | 12 | interface ICertificateListItemProps { 13 | chooseCert: () => void; 14 | selectedCert: (event: any) => void; 15 | operation: string; 16 | isOpen: boolean; 17 | toggleOpen: () => void; 18 | crl: any; 19 | } 20 | 21 | class CRLListItem extends React.Component { 22 | static contextTypes = { 23 | locale: PropTypes.string, 24 | localize: PropTypes.func, 25 | }; 26 | 27 | shouldComponentUpdate(nextProps: ICertificateListItemProps) { 28 | return nextProps.isOpen !== this.props.isOpen; 29 | } 30 | 31 | handleClick = () => { 32 | const { chooseCert, toggleOpen } = this.props; 33 | 34 | chooseCert(); 35 | toggleOpen(); 36 | } 37 | 38 | render() { 39 | const { crl, isOpen } = this.props; 40 | let active = ""; 41 | let rectangleStyle; 42 | 43 | const status = this.checkCRL(crl); 44 | 45 | if (status) { 46 | rectangleStyle = rectangleValidStyle; 47 | } else { 48 | rectangleStyle = rectangleUnvalidStyle; 49 | } 50 | 51 | if (isOpen) { 52 | active = "active"; 53 | } 54 | 55 | return ( 56 |
57 |
58 |
59 |
60 |
{crl.issuerFriendlyName}
61 |
{crl.issuerFriendlyName}
62 |
63 |
64 |
65 | ); 66 | } 67 | 68 | checkCRL = (crl: any) => { 69 | const currentDate = new Date(); 70 | 71 | if (((new Date(crl.nextUpdate)).getTime() >= currentDate.getTime()) && 72 | ((new Date(crl.lastUpdate)).getTime() <= currentDate.getTime())) { 73 | return true; 74 | } else { 75 | // 76 | } 77 | 78 | return false; 79 | } 80 | } 81 | 82 | export default CRLListItem; 83 | -------------------------------------------------------------------------------- /app/components/Certificate/CertificateInfoTabs.tsx: -------------------------------------------------------------------------------- 1 | import PropTypes from "prop-types"; 2 | import React from "react"; 3 | 4 | const tabHeaderStyle = { 5 | "font-size": "55%", 6 | }; 7 | 8 | interface ICertificateInfoTabsProps { 9 | activeCertInfoTab: (active: boolean) => void; 10 | } 11 | 12 | class CertificateInfoTabs extends React.Component { 13 | static contextTypes = { 14 | locale: PropTypes.string, 15 | localize: PropTypes.func, 16 | }; 17 | 18 | componentDidMount() { 19 | $(document).ready(function() { 20 | $("ul.tabs").tabs(); 21 | }); 22 | 23 | $(document).ready(function() { 24 | $("ul.tabs").tabs("select_tab", "tab_id"); 25 | }); 26 | } 27 | 28 | render() { 29 | const { localize, locale } = this.context; 30 | const { activeCertInfoTab } = this.props; 31 | 32 | return ( 33 | 47 | ); 48 | } 49 | } 50 | 51 | export default CertificateInfoTabs; 52 | -------------------------------------------------------------------------------- /app/components/CheckBoxWithLabel.tsx: -------------------------------------------------------------------------------- 1 | import React from "react"; 2 | 3 | interface ICheckBoxWithLabelProps { 4 | disabled?: boolean; 5 | onClickCheckBox: (event: any) => void; 6 | isChecked: boolean; 7 | elementId: string; 8 | title: string; 9 | } 10 | 11 | class CheckBoxWithLabel extends React.Component { 12 | render() { 13 | const { disabled, isChecked, onClickCheckBox, elementId, title } = this.props; 14 | 15 | const classDisabled = disabled ? "disabled" : ""; 16 | 17 | return
18 |
{title}
19 |
20 | 27 | 28 | 29 |
30 |
; 31 | } 32 | } 33 | 34 | export default CheckBoxWithLabel; 35 | -------------------------------------------------------------------------------- /app/components/CloudCSP/AuthWebView.tsx: -------------------------------------------------------------------------------- 1 | import PropTypes from "prop-types"; 2 | import React from "react"; 3 | import ProgressBars from "../ProgressBars"; 4 | 5 | interface IAuthWebViewProps { 6 | auth: string; 7 | onCancel: () => void; 8 | onTokenGet: (token: string) => void; 9 | } 10 | 11 | interface IAuthWebViewState { 12 | isLoading: boolean; 13 | url: string; 14 | } 15 | 16 | class AuthWebView extends React.PureComponent { 17 | constructor(props: IAuthWebViewProps) { 18 | super(props); 19 | this.state = { 20 | isLoading: false, 21 | // tslint:disable-next-line:max-line-length 22 | url: `${this.props.auth}/authorize?client_id=digt&response_type=token&scope=dss&redirect_uri=https://net.trusted.ru/idp/sso/authorize?auth_type=dss&resource=https://dss.cryptopro.ru/SignServer/rest/api/certificates`, 23 | }; 24 | } 25 | 26 | componentDidMount() { 27 | const webview = document.querySelector("webview"); 28 | 29 | if (webview) { 30 | webview.addEventListener("did-start-loading", this.loadStart); 31 | webview.addEventListener("did-stop-loading", this.loadStop); 32 | webview.addEventListener("did-get-redirect-request", (details) => this.redirect(details)); 33 | } 34 | } 35 | 36 | render() { 37 | const { isLoading } = this.state; 38 | 39 | return ( 40 | 41 | { 42 | isLoading ? : null 43 | } 44 | 45 | 46 | ); 47 | } 48 | 49 | loadStart = () => { 50 | this.setState({ isLoading: true }); 51 | } 52 | 53 | loadStop = () => { 54 | this.setState({ isLoading: false }); 55 | } 56 | 57 | redirect = (details) => { 58 | const regex = /^https:\/\/net.trusted.ru\/idp\/sso\/authorize\?auth_type=dss&access_token=([^&]*)/; 59 | const mathes = regex.exec(details.newURL); 60 | if (mathes) { 61 | const token = mathes[1]; 62 | 63 | if (token && token.length) { 64 | this.props.onTokenGet(token); 65 | } 66 | 67 | this.props.onCancel(); 68 | } 69 | } 70 | } 71 | 72 | export default AuthWebView; 73 | -------------------------------------------------------------------------------- /app/components/Containers/ContainerListItem.tsx: -------------------------------------------------------------------------------- 1 | import PropTypes from "prop-types"; 2 | import React from "react"; 3 | 4 | class ContainerListItem extends React.Component { 5 | static contextTypes = { 6 | locale: PropTypes.string, 7 | localize: PropTypes.func, 8 | }; 9 | 10 | shouldComponentUpdate(nextProps: { isOpen: boolean; }) { 11 | return nextProps.isOpen !== this.props.isOpen; 12 | } 13 | 14 | handleClick = () => { 15 | const { activeContainer } = this.props; 16 | 17 | activeContainer(); 18 | } 19 | 20 | render() { 21 | const { container, isOpen } = this.props; 22 | let active = ""; 23 | 24 | if (isOpen) { 25 | active = "active"; 26 | } 27 | 28 | return ( 29 | 30 |
31 |
32 |
33 | 34 |
35 |
36 |
{container.friendlyName}
37 |
{container.reader}
38 |
39 |
40 |
41 |
42 | ); 43 | } 44 | } 45 | 46 | export default ContainerListItem; 47 | -------------------------------------------------------------------------------- /app/components/Diagnostic/DiagnosticModal.tsx: -------------------------------------------------------------------------------- 1 | import PropTypes from "prop-types"; 2 | import React from "react"; 3 | import HeaderWorkspaceBlock from "../HeaderWorkspaceBlock"; 4 | 5 | interface IDiagnosticModalProps { 6 | isOpen: boolean; 7 | header: string; 8 | onClose?: () => void; 9 | } 10 | 11 | class DiagnosticModal extends React.Component { 12 | static contextTypes = { 13 | locale: PropTypes.string, 14 | localize: PropTypes.func, 15 | }; 16 | 17 | componentWillReceiveProps(newProps: IDiagnosticModalProps) { 18 | const { isOpen } = newProps; 19 | 20 | if (!this.props.isOpen && !isOpen) { 21 | return; 22 | } 23 | } 24 | 25 | componentDidMount() { 26 | const { isOpen } = this.props; 27 | 28 | if (isOpen) { 29 | $("#modal-window-diagnostic").openModal({ dismissible: false }); 30 | } 31 | } 32 | 33 | handleCloseModal = () => { 34 | const { onClose } = this.props; 35 | 36 | if (onClose) { 37 | onClose(); 38 | } 39 | 40 | $("#modal-window-diagnostic").closeModal(); 41 | } 42 | 43 | render() { 44 | const { isOpen, header } = this.props; 45 | 46 | if (!isOpen) { 47 | return null; 48 | } 49 | 50 | return ( 51 | 64 | ); 65 | } 66 | } 67 | 68 | export default DiagnosticModal; 69 | -------------------------------------------------------------------------------- /app/components/Dialog.tsx: -------------------------------------------------------------------------------- 1 | import PropTypes from "prop-types"; 2 | import React from "react"; 3 | import HeaderWorkspaceBlock from "./HeaderWorkspaceBlock"; 4 | 5 | interface IDialogProps { 6 | isOpen: boolean; 7 | header: string; 8 | body?: string; 9 | onYes: () => void; 10 | onNo: () => void; 11 | } 12 | 13 | interface IDialogState { 14 | active: boolean; 15 | } 16 | 17 | class Dialog extends React.Component { 18 | static contextTypes = { 19 | locale: PropTypes.string, 20 | localize: PropTypes.func, 21 | }; 22 | 23 | constructor(props: IDialogProps) { 24 | super(props); 25 | this.state = { 26 | active: props.isOpen, 27 | }; 28 | } 29 | 30 | componentWillReceiveProps(newProps: IDialogProps) { 31 | const { isOpen } = newProps; 32 | 33 | if (this.state.active !== isOpen) { 34 | this.setState({ active: isOpen }); 35 | } 36 | } 37 | 38 | render() { 39 | const { localize, locale } = this.context; 40 | const { header, body } = this.props; 41 | const { active } = this.state; 42 | 43 | if (!active) { 44 | return null; 45 | } 46 | 47 | return ( 48 |
49 | 63 |
64 | ); 65 | } 66 | 67 | handleYes = () => { 68 | this.props.onYes(); 69 | this.setState({ active: false }); 70 | } 71 | 72 | handleNo = () => { 73 | this.props.onNo(); 74 | this.setState({ active: false }); 75 | } 76 | } 77 | 78 | export default Dialog; 79 | -------------------------------------------------------------------------------- /app/components/Documents/DeleteDocuments.tsx: -------------------------------------------------------------------------------- 1 | import PropTypes from "prop-types"; 2 | import React from "react"; 3 | import { USER_NAME } from "../../constants"; 4 | import logger from "../../winstonLogger"; 5 | 6 | interface IDeleteDocumentsProps { 7 | onCancel?: () => void; 8 | removeDocuments: () => void; 9 | } 10 | 11 | class DeleteDocuments extends React.Component { 12 | static contextTypes = { 13 | locale: PropTypes.string, 14 | localize: PropTypes.func, 15 | }; 16 | 17 | componentWillUnmount() { 18 | this.handelCancel(); 19 | } 20 | 21 | render() { 22 | const { removeDocuments } = this.props; 23 | const { localize, locale } = this.context; 24 | 25 | return ( 26 | 27 |
28 |
29 | 30 | {localize("Documents.realy_delete_documents", locale)} 31 | 32 |
33 |
34 |
35 | 43 |
44 |
45 | ); 46 | } 47 | 48 | handelCancel = () => { 49 | const { onCancel } = this.props; 50 | 51 | if (onCancel) { 52 | onCancel(); 53 | } 54 | } 55 | } 56 | 57 | export default DeleteDocuments; 58 | -------------------------------------------------------------------------------- /app/components/EncodingTypeSelector.tsx: -------------------------------------------------------------------------------- 1 | import PropTypes from "prop-types"; 2 | import React from "react"; 3 | import ReactDOM from "react-dom"; 4 | 5 | interface IEncodingTypeSelectorProps { 6 | EncodingValue: string; 7 | disabled?: boolean; 8 | handleChange: (encoding: string) => void; 9 | } 10 | 11 | class EncodingTypeSelector extends React.Component { 12 | static contextTypes = { 13 | locale: PropTypes.string, 14 | localize: PropTypes.func, 15 | }; 16 | 17 | /** 18 | * https://github.com/facebook/react/issues/3667 19 | */ 20 | componentDidMount() { 21 | const self = this; 22 | $(document).ready(() => { 23 | $("select").material_select(); 24 | $("select").on("change", function() { 25 | self.changeEncoding($(this)[0].value); 26 | }); 27 | }); 28 | $(ReactDOM.findDOMNode(this.refs.select)).on("change", this.handleChange); 29 | } 30 | 31 | changeEncoding = (encoding: string) => { 32 | this.props.handleChange(encoding); 33 | } 34 | 35 | render() { 36 | const { localize, locale } = this.context; 37 | const classDisabled = this.props.disabled ? "disabled" : ""; 38 | 39 | return ( 40 |
41 |
{localize("Settings.encoding", locale)}
42 |
43 | 47 |
48 |
49 | ); 50 | } 51 | } 52 | 53 | export default EncodingTypeSelector; 54 | -------------------------------------------------------------------------------- /app/components/Files/fileManager.ts: -------------------------------------------------------------------------------- 1 | import * as fs from "fs"; 2 | import * as path from "path"; 3 | import { push } from "react-router-redux"; 4 | import { 5 | LOCATION_ENCRYPT, LOCATION_SIGN, REMOVE_ALL_FILES, REMOVE_ALL_REMOTE_FILES, SELECT_FILE, 6 | } from "../../constants"; 7 | import { DECRYPT, ENCRYPT, SIGN, VERIFY } from "../../constants"; 8 | import store from "../../store/index"; 9 | import { extFile, fileExists } from "../../utils"; 10 | 11 | const remote = window.electron.remote; 12 | const ipcRenderer = window.electron.ipcRenderer; 13 | 14 | ipcRenderer.on("cmdArgs", (event, cmdArgs) => { 15 | if (cmdArgs && Array.isArray(cmdArgs) && cmdArgs.length >= 2) { 16 | const openFilePath = cmdArgs[1]; 17 | 18 | openFile(openFilePath); 19 | } 20 | }); 21 | 22 | const openFile = (openFilePath: string) => { 23 | if (openFilePath && fileExists(openFilePath)) { 24 | cleanFileLists(); 25 | 26 | const file = getFileProperty(openFilePath); 27 | 28 | store.dispatch({ 29 | generateId: true, 30 | payload: { 31 | file, 32 | }, 33 | type: SELECT_FILE, 34 | }); 35 | 36 | if (file.extension === "enc") { 37 | openWindow(ENCRYPT); 38 | } else { 39 | openWindow(SIGN); 40 | } 41 | } 42 | }; 43 | 44 | const cleanFileLists = () => { 45 | store.dispatch({ type: REMOVE_ALL_FILES }); 46 | store.dispatch({ type: REMOVE_ALL_REMOTE_FILES }); 47 | }; 48 | 49 | const getFileProperty = (filepath: string) => { 50 | const stat = fs.statSync(filepath); 51 | 52 | const extension = extFile(filepath); 53 | 54 | return { 55 | extension, 56 | filename: path.basename(filepath), 57 | fullpath: filepath, 58 | lastModifiedDate: stat.birthtime, 59 | size: stat.size, 60 | }; 61 | }; 62 | 63 | const openWindow = (operation: string) => { 64 | remote.getCurrentWindow().show(); 65 | remote.getCurrentWindow().focus(); 66 | 67 | switch (operation) { 68 | case SIGN: 69 | case VERIFY: 70 | store.dispatch(push(LOCATION_SIGN)); 71 | return; 72 | 73 | case ENCRYPT: 74 | case DECRYPT: 75 | store.dispatch(push(LOCATION_ENCRYPT)); 76 | return; 77 | 78 | default: 79 | return; 80 | } 81 | }; 82 | -------------------------------------------------------------------------------- /app/components/Footer.tsx: -------------------------------------------------------------------------------- 1 | import PropTypes from "prop-types"; 2 | import React from "react"; 3 | 4 | class Footer extends React.Component<{}, {}> { 5 | static contextTypes = { 6 | locale: PropTypes.string, 7 | localize: PropTypes.func, 8 | }; 9 | 10 | shouldComponentUpdate(nextContext: { locale: string }) { 11 | return (this.context.locale !== nextContext.locale) ? true : false; 12 | } 13 | 14 | render() { 15 | const { localize, locale } = this.context; 16 | 17 | return ( 18 | 19 |
20 |
21 |
22 |
23 | 24 |
25 |
26 |
27 |
28 | {localize("About.company_name", locale)}
{localize("About.copyright", locale)} 29 |
30 |
31 |
32 |
33 |
34 |
35 |
36 | ); 37 | } 38 | } 39 | 40 | export default Footer; 41 | -------------------------------------------------------------------------------- /app/components/HeaderWorkspaceBlock.tsx: -------------------------------------------------------------------------------- 1 | import React from "react"; 2 | 3 | interface IHeaderWorkspaceBlockProps { 4 | text: string; 5 | second_text?: string; 6 | onСlickBtn?: () => void; 7 | icon?: string; 8 | new_class?: string; 9 | } 10 | 11 | class HeaderWorkspaceBlock extends React.Component { 12 | getButtons() { 13 | const { icon, onСlickBtn } = this.props; 14 | 15 | if (icon && onСlickBtn) { 16 | return (
  • 17 | 18 | {icon} 19 | 20 |
  • ); 21 | } else { 22 | return null; 23 | } 24 | } 25 | 26 | render() { 27 | const { text, second_text, new_class } = this.props; 28 | const name = new_class ? new_class : ""; 29 | 30 | let element: any; 31 | if (second_text) { 32 | element =
    33 |
    {text}
    34 |
    {second_text}
    35 |
    ; 36 | } else { 37 | element = {text}; 38 | } 39 | 40 | return ( 41 | 49 | ); 50 | } 51 | } 52 | 53 | export default HeaderWorkspaceBlock; 54 | -------------------------------------------------------------------------------- /app/components/LocaleSelect.tsx: -------------------------------------------------------------------------------- 1 | import React from "react"; 2 | import { connect } from "react-redux"; 3 | import { changeLocale } from "../AC"; 4 | import { EN, RU } from "../constants"; 5 | 6 | interface ILocaleSelectProps { 7 | changeLocale: (locale: string) => void; 8 | locale: string; 9 | } 10 | 11 | class LocaleSelect extends React.Component { 12 | handleChange = () => { 13 | // tslint:disable-next-line:no-shadowed-variable 14 | const { locale, changeLocale } = this.props; 15 | 16 | locale === RU ? changeLocale(EN) : changeLocale(RU); 17 | window.locale = locale === RU ? EN : RU; 18 | } 19 | 20 | render() { 21 | const { locale } = this.props; 22 | 23 | return ( 24 |
    25 | {locale} 26 |
    27 | ); 28 | } 29 | } 30 | 31 | export default connect((state) => ({ 32 | locale: state.settings.locale, 33 | }), { changeLocale })(LocaleSelect); 34 | -------------------------------------------------------------------------------- /app/components/MainWindow/MainWindowOperation.tsx: -------------------------------------------------------------------------------- 1 | import React from "react"; 2 | import { Link } from "react-router-dom"; 3 | 4 | interface IMainWindowOperationsProps { 5 | info: string; 6 | title_pre: string; 7 | title_post: string; 8 | operation: string; 9 | } 10 | 11 | class MainWindowOperation extends React.Component { 12 | render() { 13 | const { info, title_pre, title_post, operation } = this.props; 14 | 15 | return ( 16 | 17 | 18 |
    19 |
    20 |
    21 |
    22 |
    {title_pre}
    {title_post}
    23 |
    24 |
    25 |

    {info}

    26 |
    27 | 28 |
    29 | ); 30 | } 31 | } 32 | 33 | export default MainWindowOperation; 34 | -------------------------------------------------------------------------------- /app/components/Modal.tsx: -------------------------------------------------------------------------------- 1 | import PropTypes from "prop-types"; 2 | import React from "react"; 3 | import HeaderWorkspaceBlock from "./HeaderWorkspaceBlock"; 4 | 5 | interface IModalProps { 6 | isOpen: boolean; 7 | header: string; 8 | onClose?: () => void; 9 | style?: any; 10 | } 11 | 12 | class Modal extends React.Component { 13 | static contextTypes = { 14 | locale: PropTypes.string, 15 | localize: PropTypes.func, 16 | }; 17 | 18 | componentWillReceiveProps(newProps: IModalProps) { 19 | const { isOpen } = newProps; 20 | 21 | if (!this.props.isOpen && !isOpen) { 22 | return; 23 | } 24 | } 25 | 26 | componentDidMount() { 27 | const { isOpen } = this.props; 28 | 29 | if (isOpen) { 30 | $("#modal-window").openModal({ dismissible: false }); 31 | } 32 | } 33 | 34 | componentWillUnmount() { 35 | $("#modal-window").closeModal(); 36 | } 37 | 38 | handleCloseModal = () => { 39 | const { onClose } = this.props; 40 | 41 | if (onClose) { 42 | onClose(); 43 | } 44 | 45 | $("#modal-window").closeModal(); 46 | } 47 | 48 | render() { 49 | const { isOpen, header } = this.props; 50 | 51 | if (!isOpen) { 52 | return null; 53 | } 54 | 55 | return ( 56 | 69 | ); 70 | } 71 | } 72 | 73 | export default Modal; 74 | -------------------------------------------------------------------------------- /app/components/ProgressBars.tsx: -------------------------------------------------------------------------------- 1 | import PropTypes from "prop-types"; 2 | import React from "react"; 3 | 4 | export default function ProgressBars({ }, context: { localize: (str: string, locale: string) => string; locale: string; }) { 5 | const { localize, locale } = context; 6 | 7 | return ( 8 |
    9 |
    10 |
    11 |
    12 |
    13 |
    14 |
    15 |
    16 |
    17 |
    18 |
    19 |
    20 |
    21 |
    22 |
    {localize("Settings.wait", locale)}
    23 |
    24 | ); 25 | } 26 | 27 | ProgressBars.contextTypes = { 28 | locale: PropTypes.string, 29 | localize: PropTypes.func, 30 | }; 31 | -------------------------------------------------------------------------------- /app/components/Request/HeaderTabs.tsx: -------------------------------------------------------------------------------- 1 | import PropTypes from "prop-types"; 2 | import React from "react"; 3 | 4 | interface IHeaderTabsProps { 5 | activeSubjectNameInfoTab: (active: boolean) => void; 6 | } 7 | 8 | class HeaderTabs extends React.Component { 9 | static contextTypes = { 10 | locale: PropTypes.string, 11 | localize: PropTypes.func, 12 | }; 13 | 14 | componentDidMount() { 15 | $(document).ready(() => { 16 | $("ul.tabs").tabs(); 17 | }); 18 | 19 | $(document).ready(() => { 20 | $("ul.tabs").tabs("select_tab", "tab_id"); 21 | }); 22 | } 23 | 24 | render() { 25 | const { localize, locale } = this.context; 26 | const { activeSubjectNameInfoTab } = this.props; 27 | 28 | return ( 29 | 43 | ); 44 | } 45 | } 46 | 47 | export default HeaderTabs; 48 | -------------------------------------------------------------------------------- /app/components/Request/RequestButtons.tsx: -------------------------------------------------------------------------------- 1 | import PropTypes from "prop-types"; 2 | import React from "react"; 3 | 4 | interface IRequestButtonsProps { 5 | onCopy: () => void; 6 | } 7 | 8 | class RequestButtons extends React.Component { 9 | static contextTypes = { 10 | locale: PropTypes.string, 11 | localize: PropTypes.func, 12 | }; 13 | 14 | render() { 15 | const { localize, locale } = this.context; 16 | 17 | return ( 18 | 23 | ); 24 | 25 | } 26 | } 27 | 28 | export default RequestButtons; 29 | -------------------------------------------------------------------------------- /app/components/Root.tsx: -------------------------------------------------------------------------------- 1 | import React from "react"; 2 | import {hot} from "react-hot-loader/root"; 3 | import { Provider } from "react-redux"; 4 | import App from "./App"; 5 | 6 | class Root extends React.Component { 7 | render() { 8 | return ( 9 | 10 | 11 | 12 | ); 13 | } 14 | } 15 | 16 | export default hot(Root); 17 | -------------------------------------------------------------------------------- /app/components/SelectFolder.tsx: -------------------------------------------------------------------------------- 1 | import PropTypes from "prop-types"; 2 | import React from "react"; 3 | 4 | interface ISelectFolderProps { 5 | disabled?: boolean; 6 | directory: string; 7 | viewDirect: (event: any) => void; 8 | openDirect: () => void; 9 | } 10 | 11 | class SelectFolder extends React.Component { 12 | static contextTypes = { 13 | locale: PropTypes.string, 14 | localize: PropTypes.func, 15 | }; 16 | 17 | render() { 18 | const { localize, locale } = this.context; 19 | const { disabled } = this.props; 20 | 21 | const classDisabled = disabled ? "disabled" : ""; 22 | 23 | return ( 24 |
    25 |
    26 | node && node.setAttribute("nwdirectory", "")} id="choose-folder" onChange={this.props.viewDirect} disabled={disabled} /> 27 | 29 | 30 | create_new_folder 31 | 32 |
    33 |
    34 | ); 35 | } 36 | } 37 | 38 | export default SelectFolder; 39 | -------------------------------------------------------------------------------- /app/components/Services/ServiceIcon.tsx: -------------------------------------------------------------------------------- 1 | import React from "react"; 2 | 3 | interface IFileIconProps { 4 | type: string; 5 | } 6 | 7 | class ServiceIcon extends React.Component { 8 | render() { 9 | const { type } = this.props; 10 | 11 | return ( 12 |
    13 |
    14 |
    15 | 16 |
    17 |
    18 |
    19 | ); 20 | } 21 | } 22 | 23 | export default ServiceIcon; 24 | -------------------------------------------------------------------------------- /app/components/Services/ServicesList.tsx: -------------------------------------------------------------------------------- 1 | import React from "react"; 2 | import ServicesListItem from "./ServicesListItem"; 3 | import { IService } from "./types"; 4 | 5 | interface IServicesListProps { 6 | activeService?: IService; 7 | onListItemClick: (service: IService) => (service: IService) => void; 8 | services: IService[]; 9 | } 10 | 11 | class ServicesList extends React.PureComponent { 12 | constructor(props: IServicesListProps) { 13 | super(props); 14 | } 15 | 16 | render() { 17 | const { services } = this.props; 18 | 19 | if (!services || !services.length) { 20 | return null; 21 | } 22 | 23 | return ( 24 |
    25 | {this.getBody(services)} 26 |
    27 | ); 28 | } 29 | 30 | getBody = (services: IService[]) => { 31 | const body = services.map((service) => { 32 | return ; 38 | }); 39 | 40 | return body; 41 | } 42 | 43 | isItemOpened = (id: string) => { 44 | return this.props.activeService ? this.props.activeService.id === id : false; 45 | } 46 | } 47 | 48 | export default ServicesList; 49 | -------------------------------------------------------------------------------- /app/components/Services/ServicesListItem.tsx: -------------------------------------------------------------------------------- 1 | import React from "react"; 2 | import { CRYPTOPRO_DSS, CRYPTOPRO_DSS_NAME, CRYPTOPRO_SVS, CRYPTOPRO_SVS_NAME } from "../../constants"; 3 | import { MEGAFON, MEGAFON_NAME } from "../../service/megafon/constants"; 4 | import ServiceIcon from "./ServiceIcon"; 5 | import { IService } from "./types"; 6 | 7 | interface IServicesListItemProps { 8 | active: boolean; 9 | onClick: (service: IService) => void; 10 | service: IService; 11 | } 12 | 13 | class ServicesListItem extends React.PureComponent { 14 | render() { 15 | const { active, service } = this.props; 16 | 17 | const activeType = active ? "active" : ""; 18 | 19 | return ( 20 |
    this.props.onClick(service)}> 21 |
    22 |
    23 | 24 |
    25 |
    26 |
    {this.getTitle(service)}
    27 |
    {this.getInfo(service)}
    28 |
    29 |
    30 |
    31 | ); 32 | } 33 | 34 | getTitle = (service: IService) => { 35 | switch (service.type) { 36 | case MEGAFON: 37 | return service.name ? service.name : MEGAFON_NAME; 38 | 39 | case CRYPTOPRO_DSS: 40 | return service.name ? service.name : CRYPTOPRO_DSS_NAME; 41 | 42 | case CRYPTOPRO_SVS: 43 | return service.name ? service.name : CRYPTOPRO_SVS_NAME; 44 | 45 | default: 46 | return service.type; 47 | } 48 | } 49 | 50 | getInfo = (service: IService) => { 51 | switch (service.type) { 52 | case MEGAFON: 53 | return service.settings ? service.settings.mobileNumber : ""; 54 | 55 | case CRYPTOPRO_DSS: 56 | return service.settings ? service.settings.authURL : ""; 57 | 58 | case CRYPTOPRO_SVS: 59 | return service.settings ? service.settings.hostName : ""; 60 | 61 | default: 62 | return service.type; 63 | } 64 | } 65 | } 66 | 67 | export default ServicesListItem; 68 | -------------------------------------------------------------------------------- /app/components/Services/types.ts: -------------------------------------------------------------------------------- 1 | export interface IMegafonSettings { 2 | mobileNumber: string; 3 | } 4 | 5 | export interface ICryptoProSettings { 6 | authURL: string; 7 | restURL: string; 8 | } 9 | 10 | export interface ICryptoProSVSSettings { 11 | hostName: string; 12 | applicationName: string; 13 | } 14 | 15 | export interface IService { 16 | id: string; 17 | type: "MEGAFON" | "CRYPTOPRO_DSS" | "CRYPTOPRO_SVS"; 18 | settings: IMegafonSettings & ICryptoProSettings & ICryptoProSVSSettings; 19 | name: string; 20 | } 21 | -------------------------------------------------------------------------------- /app/components/Signature/SignatureInfoBlock.tsx: -------------------------------------------------------------------------------- 1 | import PropTypes from "prop-types"; 2 | import React from "react"; 3 | import HeaderWorkspaceBlock from "../HeaderWorkspaceBlock"; 4 | import SignerCertificateInfo from "../SignerCertificateInfo"; 5 | import SignatureStatus from "./SignatureStatus"; 6 | 7 | class SignatureInfoBlock extends React.Component { 8 | static contextTypes = { 9 | locale: PropTypes.string, 10 | localize: PropTypes.func, 11 | }; 12 | 13 | render() { 14 | const { signerCertificate, filename, signatures, handleActiveCert, handleNoShowSignatureInfo, handleNoShowSignerCertificateInfo } = this.props; 15 | const { localize, locale } = this.context; 16 | 17 | if (!signatures) { 18 | return null; 19 | } 20 | 21 | if (signerCertificate) { 22 | return ( 23 | 24 | ); 25 | } 26 | 27 | const elements = signatures.map((signature: any) => { 28 | return ; 29 | }); 30 | 31 | return ( 32 |
    33 |
    34 |
    35 | 36 |
    37 |
    38 | {elements} 39 |
    40 |
    41 |
    42 |
    43 |
    44 | ); 45 | } 46 | } 47 | 48 | export default SignatureInfoBlock; 49 | -------------------------------------------------------------------------------- /app/components/Sort/SortDirection.ts: -------------------------------------------------------------------------------- 1 | interface ISortDirection { 2 | ASC: "ASC"; 3 | DESC: "DESC"; 4 | } 5 | 6 | const SortDirection: ISortDirection = { 7 | /** 8 | * Sort items in ascending order. 9 | */ 10 | ASC: "ASC", 11 | 12 | /** 13 | * Sort items in descending order. 14 | */ 15 | DESC: "DESC", 16 | }; 17 | 18 | export default SortDirection; 19 | -------------------------------------------------------------------------------- /app/components/Sort/SortIndicator.tsx: -------------------------------------------------------------------------------- 1 | import cn from "classnames"; 2 | import React from "react"; 3 | import SortDirection from "./SortDirection"; 4 | 5 | type TSortDirection = "ASC" | "DESC" | undefined; 6 | 7 | /** 8 | * Displayed beside a header to indicate that a Table is currently sorted by this column. 9 | */ 10 | export default function SortIndicator({ sortDirection }: { sortDirection: TSortDirection }) { 11 | const classNames = cn("ReactVirtualized__Table__sortableHeaderIcon", { 12 | "ReactVirtualized__Table__sortableHeaderIcon--ASC": 13 | sortDirection === SortDirection.ASC, 14 | "ReactVirtualized__Table__sortableHeaderIcon--DESC": 15 | sortDirection === SortDirection.DESC, 16 | }); 17 | 18 | return ( 19 | 20 | { 21 | sortDirection === SortDirection.ASC ? ( 22 | 23 | ) : ( 24 | 25 | ) 26 | } 27 | 28 | 29 | ); 30 | } 31 | -------------------------------------------------------------------------------- /app/components/ToolBarForEncryptCertificateBlock.tsx: -------------------------------------------------------------------------------- 1 | import PropTypes from "prop-types"; 2 | import React from "react"; 3 | 4 | const appBarStyle = { 5 | width: "calc(100% - 85px)", 6 | }; 7 | 8 | class ToolBarForEncryptCertificateBlock extends React.Component { 9 | static contextTypes = { 10 | locale: PropTypes.string, 11 | localize: PropTypes.func, 12 | }; 13 | 14 | render() { 15 | const { localize, locale } = this.context; 16 | const { certificates, recipients, handleCleanRecipientsList, onСlickBtn } = this.props; 17 | 18 | const ACTIVE = recipients.length > 0 ? "" : "not-active"; 19 | 20 | return ; 36 | } 37 | } 38 | 39 | export default ToolBarForEncryptCertificateBlock; 40 | -------------------------------------------------------------------------------- /app/decorators/accordion.tsx: -------------------------------------------------------------------------------- 1 | import React from "react"; 2 | 3 | export default (CustomComponent: any) => class AccordionDecorator extends React.Component { 4 | constructor(props: any) { 5 | super(props); 6 | this.state = { 7 | openItemId: null, 8 | }; 9 | } 10 | 11 | toggleOpenItem = (openItemId: any) => (ev: any) => { 12 | if (ev && ev.preventDefault) { 13 | ev.preventDefault(); 14 | } 15 | 16 | this.setState({ 17 | openItemId: this.isItemOpened(openItemId) ? null : openItemId, 18 | }); 19 | } 20 | 21 | isItemOpened = (id: number) => id === this.state.openItemId; 22 | 23 | render() { 24 | return ; 25 | } 26 | }; 27 | -------------------------------------------------------------------------------- /app/errors.ts: -------------------------------------------------------------------------------- 1 | export const ERROR_LOAD_TRUSTED_CRYPTO = "ERROR_LOAD_TRUSTED_CRYPTO"; 2 | export const NOT_INSTALLED_CSP = "NOT_INSTALLED_CSP"; 3 | export const ERROR_CHECK_CSP_LICENSE = "ERROR_CHECK_CSP_LICENSE"; 4 | export const NO_GOST_2001 = "NO_GOST_2001"; 5 | export const ERROR_CHECK_CSP_PARAMS = "ERROR_CHECK_CSP_PARAMS"; 6 | export const NO_CRYPTOARM_LICENSE = "NO_CRYPTOARM_LICENSE"; 7 | export const NO_CORRECT_CRYPTOARM_LICENSE = "NO_CORRECT_CRYPTOARM_LICENSE"; 8 | export const NO_HAVE_CERTIFICATES_WITH_KEY = "NO_HAVE_CERTIFICATES_WITH_KEY"; 9 | 10 | export const WARNING = "WARNING"; 11 | export const BUG = "BUG"; 12 | -------------------------------------------------------------------------------- /app/history.ts: -------------------------------------------------------------------------------- 1 | import createHistory from "history/createBrowserHistory"; 2 | 3 | const history = createHistory(); 4 | 5 | export default history; 6 | -------------------------------------------------------------------------------- /app/index.d.ts: -------------------------------------------------------------------------------- 1 | interface Window { 2 | APP_LOG_FILE: string; 3 | APP_ERRORS_LOG_FILE: string; 4 | USER_NAME: string; 5 | mainWindow: any; 6 | electron: any; 7 | framework_NW: boolean; 8 | TRUSTEDCERTIFICATECOLLECTION: trusted.pki.CertificateCollection; 9 | PKIITEMS: Array; 10 | PKISTORE: any; 11 | RESOURCES_PATH: string; 12 | DEFAULT_PATH: string; 13 | HOME_DIR: string; 14 | TMP_DIR: string; 15 | DEFAULT_CERTSTORE_PATH: string; 16 | DEFAULT_DOCUMENTS_PATH: string; 17 | DEFAULT_CSR_PATH: string; 18 | LICENSE_PATH: string; 19 | PLATFORM: string; 20 | SETTINGS_JSON: string; 21 | SERVICES_JSON: string; 22 | TRUSTED_CRYPTO_LOG: string; 23 | fs: any; 24 | os: any; 25 | archiver: any; 26 | async: any; 27 | path: any; 28 | sudo: any; 29 | locale: string; 30 | logger: trusted.utils.Logger; 31 | } 32 | 33 | declare var window: Window; 34 | -------------------------------------------------------------------------------- /app/middlewares/logger.ts: -------------------------------------------------------------------------------- 1 | export default store => next => action => { 2 | console.log('---', 'before', store.getState()); 3 | console.log('---', 'dispatching', action); 4 | next(action); 5 | console.log('---', 'after', store.getState()); 6 | }; 7 | -------------------------------------------------------------------------------- /app/middlewares/randomId.ts: -------------------------------------------------------------------------------- 1 | export default store => next => action => { 2 | if (!action.generateId) { 3 | return next(action); 4 | } 5 | 6 | next({ 7 | ...action, 8 | randomId: Date.now() + Math.random() 9 | }); 10 | }; 11 | -------------------------------------------------------------------------------- /app/package.json: -------------------------------------------------------------------------------- 1 | { 2 | "author": "Trusted Plus development team", 3 | "name": "trusted-esign", 4 | "productName": "trusted-esign", 5 | "version": "1.4.0", 6 | "main": "./main.js", 7 | "license": "Apache-2.0", 8 | "dependencies": { 9 | "archiver": "^3.0.0", 10 | "async": "2.3.0", 11 | "history": "^4.6.3", 12 | "immutable": "^3.8.1", 13 | "request": "^2.88.0", 14 | "reselect": "^3.0.1", 15 | "socket.io": "^2.0.4", 16 | "sudo-prompt": "^8.2.3", 17 | "winston": "^3.0.0" 18 | } 19 | } 20 | -------------------------------------------------------------------------------- /app/reducer/cloudCSP.ts: -------------------------------------------------------------------------------- 1 | import { FAIL, GET_CERTIFICATES_FROM_DSS, RESET_CLOUD_CSP, START, SUCCESS } from "../constants"; 2 | 3 | const DefaultReducerState = { 4 | certificates: [], 5 | error: null, 6 | loaded: false, 7 | loading: false, 8 | statusCode: null, 9 | }; 10 | 11 | export default (clouCSPState = DefaultReducerState, action) => { 12 | const { type, payload } = action; 13 | 14 | switch (type) { 15 | case GET_CERTIFICATES_FROM_DSS + START: 16 | return clouCSPState = { ...clouCSPState, ...DefaultReducerState, loading: true }; 17 | 18 | case GET_CERTIFICATES_FROM_DSS + SUCCESS: 19 | return clouCSPState = { 20 | ...clouCSPState, 21 | certificates: payload.certificates, 22 | loaded: true, 23 | loading: false, 24 | statusCode: payload.statusCode, 25 | }; 26 | 27 | case GET_CERTIFICATES_FROM_DSS + FAIL: 28 | return clouCSPState = { 29 | ...clouCSPState, 30 | error: payload ? payload.error : "", 31 | loaded: true, 32 | loading: false, 33 | statusCode: payload.statusCode, 34 | }; 35 | 36 | case RESET_CLOUD_CSP: 37 | return clouCSPState = { 38 | ...clouCSPState, ...DefaultReducerState, 39 | }; 40 | } 41 | 42 | return clouCSPState; 43 | }; 44 | -------------------------------------------------------------------------------- /app/reducer/connections.ts: -------------------------------------------------------------------------------- 1 | import { OrderedMap, Record } from "immutable"; 2 | import { ADD_CONNECTION, ADD_LICENSE, DELETE_ALL_TEMPORY_LICENSES, REMOVE_CONNECTION, SET_CONNECTED, SET_DISCONNECTED } from "../constants"; 3 | 4 | const ConnectionModel = Record({ 5 | connected: false, 6 | id: null, 7 | socket: null, 8 | }); 9 | 10 | const LicenseModel = Record({ 11 | id: null, 12 | license: null, 13 | }); 14 | 15 | const DefaultReducerState = Record({ 16 | entities: OrderedMap({}), 17 | licenses: OrderedMap({}), 18 | }); 19 | 20 | export default (connections = new DefaultReducerState(), action) => { 21 | const { type, payload } = action; 22 | 23 | switch (type) { 24 | case ADD_CONNECTION: 25 | return connections.setIn(["entities", payload.id], new ConnectionModel({ 26 | id: payload.id, 27 | socket: payload.socket, 28 | })); 29 | 30 | case ADD_LICENSE: 31 | return connections.setIn(["licenses", payload.id], new LicenseModel({ 32 | id: payload.id, 33 | license: payload.license, 34 | })); 35 | 36 | case DELETE_ALL_TEMPORY_LICENSES: 37 | return connections.setIn(["licenses"], OrderedMap({})); 38 | 39 | case REMOVE_CONNECTION: 40 | return connections.deleteIn(["entities", payload.id]); 41 | 42 | case SET_CONNECTED: 43 | return connections.setIn(["entities", payload.id, "connected"], true); 44 | 45 | case SET_DISCONNECTED: 46 | return connections.setIn(["entities", payload.id, "connected"], false); 47 | } 48 | 49 | return connections; 50 | }; 51 | -------------------------------------------------------------------------------- /app/reducer/containers.ts: -------------------------------------------------------------------------------- 1 | import { OrderedMap, Record } from "immutable"; 2 | import { ACTIVE_CONTAINER, GET_CERTIFICATE_FROM_CONTAINER, 3 | LOAD_ALL_CONTAINERS, REMOVE_ALL_CONTAINERS, START, SUCCESS } from "../constants"; 4 | import { arrayToMap } from "../utils"; 5 | 6 | const ContainerModel = Record({ 7 | certificate: null, 8 | certificateItem: null, 9 | certificateLoaded: false, 10 | certificateLoading: false, 11 | friendlyName: null, 12 | id: null, 13 | name: null, 14 | reader: null, 15 | }); 16 | 17 | const DefaultReducerState = Record({ 18 | active: null, 19 | entities: OrderedMap({}), 20 | loaded: false, 21 | loading: false, 22 | }); 23 | 24 | export default (sContainers = new DefaultReducerState(), action) => { 25 | const { type, containers, payload } = action; 26 | switch (type) { 27 | case ACTIVE_CONTAINER: 28 | return sContainers.set("active", payload.container); 29 | 30 | case LOAD_ALL_CONTAINERS + START: 31 | return sContainers.set("loading", true); 32 | 33 | case LOAD_ALL_CONTAINERS + SUCCESS: 34 | return sContainers 35 | .set("entities", arrayToMap(containers, ContainerModel)) 36 | .set("loading", false) 37 | .set("loaded", true); 38 | 39 | case GET_CERTIFICATE_FROM_CONTAINER + START: 40 | return sContainers.setIn(["entities", payload.container, "certificateLoading"], true); 41 | 42 | case GET_CERTIFICATE_FROM_CONTAINER + SUCCESS: 43 | return sContainers 44 | .setIn(["entities", payload.container, "certificate"], payload.certificate) 45 | .setIn(["entities", payload.container, "certificateItem"], payload.certificateItem) 46 | .setIn(["entities", payload.container, "certificateLoading"], false) 47 | .setIn(["entities", payload.container, "certificateLoaded"], true); 48 | 49 | case REMOVE_ALL_CONTAINERS: 50 | return sContainers = new DefaultReducerState(); 51 | } 52 | 53 | return sContainers; 54 | }; 55 | -------------------------------------------------------------------------------- /app/reducer/crls.ts: -------------------------------------------------------------------------------- 1 | import { OrderedMap, Record } from "immutable"; 2 | import { LOAD_ALL_CERTIFICATES, REMOVE_ALL_CERTIFICATES, 3 | START, SUCCESS, VERIFY_CERTIFICATE } from "../constants"; 4 | import { arrayToMap } from "../utils"; 5 | 6 | const CRLModel = Record({ 7 | active: false, 8 | authorityKeyid: null, 9 | category: null, 10 | crlNumber: null, 11 | format: null, 12 | hash: null, 13 | id: null, 14 | issuerFriendlyName: null, 15 | issuerName: null, 16 | lastUpdate: null, 17 | nextUpdate: null, 18 | provider: null, 19 | signatureAlgorithm: null, 20 | signatureDigestAlgorithm: null, 21 | type: null, 22 | uri: null, 23 | }); 24 | 25 | const DefaultReducerState = Record({ 26 | entities: OrderedMap({}), 27 | loaded: false, 28 | loading: false, 29 | }); 30 | 31 | export default (CRLs = new DefaultReducerState(), action) => { 32 | const { type, crls } = action; 33 | switch (type) { 34 | case LOAD_ALL_CERTIFICATES + START: 35 | return CRLs.set("loading", true); 36 | 37 | case LOAD_ALL_CERTIFICATES + SUCCESS: 38 | return CRLs 39 | .update("entities", (entities) => arrayToMap(crls, CRLModel).merge(entities)) 40 | .set("loading", false) 41 | .set("loaded", true); 42 | 43 | case REMOVE_ALL_CERTIFICATES: 44 | return CRLs = new DefaultReducerState(); 45 | } 46 | 47 | return CRLs; 48 | }; 49 | -------------------------------------------------------------------------------- /app/reducer/documents.ts: -------------------------------------------------------------------------------- 1 | import * as fs from "fs"; 2 | import { OrderedMap, OrderedSet, Record } from "immutable"; 3 | import { 4 | ARHIVE_DOCUMENTS, LOAD_ALL_DOCUMENTS, PACKAGE_DELETE_DOCUMENTS, 5 | REMOVE_ALL_DOCUMENTS, REMOVE_DOCUMENTS, SELECT_ALL_DOCUMENTS, 6 | SELECT_DOCUMENT, START, SUCCESS, UNSELECT_ALL_DOCUMENTS, 7 | } from "../constants"; 8 | import { arrayToMap, fileExists } from "../utils"; 9 | 10 | const DocumentModel = Record({ 11 | atime: null, 12 | birthtime: null, 13 | extname: null, 14 | filename: null, 15 | filesize: null, 16 | fullpath: null, 17 | id: null, 18 | mtime: null, 19 | selected: null, 20 | }); 21 | 22 | const DefaultReducerState = Record({ 23 | entities: OrderedMap({}), 24 | loaded: false, 25 | loading: false, 26 | selected: new OrderedSet([]), 27 | }); 28 | 29 | export default (documents = new DefaultReducerState(), action) => { 30 | const { type, payload } = action; 31 | 32 | switch (type) { 33 | case LOAD_ALL_DOCUMENTS + START: 34 | return documents.set("loading", true); 35 | 36 | case LOAD_ALL_DOCUMENTS + SUCCESS: 37 | return documents 38 | .set("entities", arrayToMap(payload.documents, DocumentModel)) 39 | .set("loading", false) 40 | .set("loaded", true) 41 | .set("selected", new OrderedSet([])); 42 | 43 | case REMOVE_ALL_DOCUMENTS: 44 | return documents = new DefaultReducerState(); 45 | 46 | case REMOVE_DOCUMENTS: 47 | return documents = new DefaultReducerState(); 48 | 49 | case ARHIVE_DOCUMENTS: 50 | return documents = new DefaultReducerState(); 51 | 52 | case SELECT_DOCUMENT: 53 | return documents.update("selected", (selected) => selected.has(payload.uid) 54 | ? selected.remove(payload.uid) 55 | : selected.add(payload.uid), 56 | ); 57 | 58 | case SELECT_ALL_DOCUMENTS: 59 | const allDocumentsId: number[] = []; 60 | 61 | documents.entities.map((item: any) => allDocumentsId.push(item.id)); 62 | 63 | return documents.set("selected", new OrderedSet(allDocumentsId)); 64 | 65 | case UNSELECT_ALL_DOCUMENTS: 66 | return documents.set("selected", new OrderedSet([])); 67 | 68 | } 69 | 70 | return documents; 71 | }; 72 | -------------------------------------------------------------------------------- /app/reducer/events.ts: -------------------------------------------------------------------------------- 1 | import { OrderedMap, Record } from "immutable"; 2 | import { LOAD_ALL_EVENTS, REMOVE_ALL_EVENTS, START, SUCCESS } from "../constants"; 3 | import { arrayToMap } from "../utils"; 4 | 5 | const EventModel = Record({ 6 | certificate: null, 7 | operationObject: null, 8 | id: null, 9 | level: null, 10 | message: null, 11 | operation: null, 12 | timestamp: null, 13 | userName: null, 14 | }); 15 | 16 | const DefaultReducerState = Record({ 17 | dateFrom: null, 18 | dateTo: null, 19 | entities: OrderedMap({}), 20 | isArchive: false, 21 | loaded: false, 22 | loading: false, 23 | }); 24 | 25 | export default (events = new DefaultReducerState(), action) => { 26 | const { type, payload } = action; 27 | 28 | switch (type) { 29 | case LOAD_ALL_EVENTS + START: 30 | return events.set("loading", true); 31 | 32 | case LOAD_ALL_EVENTS + SUCCESS: 33 | return events 34 | .update("entities", (entities) => arrayToMap(payload.events, EventModel).merge(entities)) 35 | .set("loading", false) 36 | .set("loaded", true) 37 | .set("dateFrom", payload.events && payload.events[0] ? payload.events[0].timestamp : null) 38 | .set("dateTo", payload.events && payload.events[payload.events.length - 1] ? payload.events[payload.events.length - 1].timestamp : null) 39 | .set("isArchive", payload.isArchive); 40 | 41 | case REMOVE_ALL_EVENTS: 42 | return events = new DefaultReducerState(); 43 | } 44 | 45 | return events; 46 | }; 47 | -------------------------------------------------------------------------------- /app/reducer/index.ts: -------------------------------------------------------------------------------- 1 | import {routerReducer as router} from "react-router-redux"; 2 | import {combineReducers} from "redux"; 3 | import certificates from "./certificates"; 4 | import cloudCSP from "./cloudCSP"; 5 | import connections from "./connections"; 6 | import containers from "./containers"; 7 | import crls from "./crls"; 8 | import documents from "./documents"; 9 | import events from "./events"; 10 | import files from "./files"; 11 | import filters from "./filters"; 12 | import megafon from "./megafon"; 13 | import recipients from "./recipients"; 14 | import remoteFiles from "./remoteFiles"; 15 | import services from "./services"; 16 | import settings from "./settings"; 17 | import signatures from "./signatures"; 18 | import signers from "./signers"; 19 | 20 | export default combineReducers({ 21 | router, 22 | certificates, 23 | cloudCSP, 24 | connections, 25 | containers, 26 | crls, 27 | documents, 28 | events, 29 | files, 30 | filters, 31 | megafon, 32 | recipients, 33 | remoteFiles, 34 | services, 35 | settings, 36 | signatures, 37 | signers, 38 | }); 39 | -------------------------------------------------------------------------------- /app/reducer/recipients.ts: -------------------------------------------------------------------------------- 1 | import { OrderedMap, Record } from "immutable"; 2 | import { ADD_RECIPIENT_CERTIFICATE, DELETE_RECIPIENT_CERTIFICATE, REMOVE_ALL_CERTIFICATES } from "../constants"; 3 | 4 | export const RecipientModel = Record({ 5 | certId: null, 6 | }); 7 | 8 | export const DefaultReducerState = Record({ 9 | entities: OrderedMap({}), 10 | }); 11 | 12 | export default (recipients = new DefaultReducerState(), action) => { 13 | const { type, payload } = action; 14 | 15 | switch (type) { 16 | case ADD_RECIPIENT_CERTIFICATE: 17 | return recipients.setIn(["entities", payload.certId], new RecipientModel({ 18 | certId: payload.certId, 19 | })); 20 | 21 | case DELETE_RECIPIENT_CERTIFICATE: 22 | return recipients.deleteIn(["entities", payload.recipient]); 23 | 24 | case REMOVE_ALL_CERTIFICATES: 25 | return recipients = new DefaultReducerState(); 26 | } 27 | 28 | return recipients; 29 | }; 30 | -------------------------------------------------------------------------------- /app/reducer/remoteFiles.ts: -------------------------------------------------------------------------------- 1 | import { OrderedMap, Record } from "immutable"; 2 | import { ADD_REMOTE_FILE, DOWNLOAD_REMOTE_FILE, REMOVE_ALL_REMOTE_FILES, SET_REMOTE_FILES_PARAMS, START, SUCCESS, UPLOAD_FILE } from "../constants"; 3 | 4 | export interface IRemoteFile { 5 | extra: any; 6 | id: number; 7 | loaded: boolean; 8 | loading: boolean; 9 | name: string; 10 | socketId: string; 11 | totalSize: number; 12 | url: string; 13 | } 14 | 15 | const FileModel = Record({ 16 | extra: null, 17 | id: null, 18 | loaded: false, 19 | loading: false, 20 | name: null, 21 | socketId: null, 22 | totalSize: null, 23 | url: null, 24 | }); 25 | 26 | const DefaultReducerState = Record({ 27 | entities: OrderedMap({}), 28 | method: null, 29 | token: null, 30 | uploader: null, 31 | }); 32 | 33 | export default (files = new DefaultReducerState(), action) => { 34 | const { type, payload } = action; 35 | 36 | switch (type) { 37 | case ADD_REMOTE_FILE: 38 | return files.setIn(["entities", payload.id], new FileModel({ 39 | id: payload.id, 40 | ...payload.file, 41 | })); 42 | 43 | case SET_REMOTE_FILES_PARAMS: 44 | return files 45 | .set("method", payload.method) 46 | .set("token", payload.token) 47 | .set("uploader", payload.uploader); 48 | 49 | case DOWNLOAD_REMOTE_FILE + START: 50 | return files 51 | .setIn(["entities", payload.id, "totalSize"], payload.totalSize) 52 | .setIn(["entities", payload.id, "loading"], true); 53 | 54 | case DOWNLOAD_REMOTE_FILE + SUCCESS: 55 | return files 56 | .setIn(["entities", payload.id, "loading"], false) 57 | .setIn(["entities", payload.id, "loaded"], true); 58 | 59 | case REMOVE_ALL_REMOTE_FILES: 60 | return files = new DefaultReducerState(); 61 | } 62 | 63 | return files; 64 | }; 65 | -------------------------------------------------------------------------------- /app/reducer/services.ts: -------------------------------------------------------------------------------- 1 | import { OrderedMap, Record } from "immutable"; 2 | import { ADD_SERVICE, CHANGE_SERVICE_NAME, CHANGE_SERVICE_SETTINGS, DELETE_SERVICE } from "../constants"; 3 | 4 | export const ServiceModel = Record({ 5 | id: null, 6 | name: null, 7 | settings: OrderedMap({}), 8 | type: null, 9 | }); 10 | 11 | export const SettingsModel = Record({ 12 | applicationName: null, 13 | authURL: null, 14 | hostName: null, 15 | mobileNumber: null, 16 | restURL: null, 17 | }); 18 | 19 | export const DefaultReducerState = Record({ 20 | entities: OrderedMap({}), 21 | }); 22 | 23 | export default (services = new DefaultReducerState(), action) => { 24 | const { type, payload } = action; 25 | 26 | switch (type) { 27 | case ADD_SERVICE: 28 | services = services.setIn(["entities", payload.service.id], new ServiceModel(payload.service)); 29 | if (payload.settings) { 30 | services = services.setIn(["entities", payload.service.id, "settings"], new SettingsModel(payload.settings)); 31 | } 32 | return services; 33 | 34 | case DELETE_SERVICE: 35 | return services 36 | .deleteIn(["entities", payload.id]); 37 | 38 | case CHANGE_SERVICE_SETTINGS: 39 | return services.setIn(["entities", payload.id, "settings"], new SettingsModel(payload.settings)); 40 | 41 | case CHANGE_SERVICE_NAME: 42 | return services.setIn(["entities", payload.id, "name"], payload.name); 43 | } 44 | 45 | return services; 46 | }; 47 | -------------------------------------------------------------------------------- /app/reducer/signatures.ts: -------------------------------------------------------------------------------- 1 | import { OrderedMap, Record } from "immutable"; 2 | import { PACKAGE_SIGN, START, SUCCESS, VERIFY_SIGNATURE } from "../constants"; 3 | import { arrayToMap } from "../utils"; 4 | 5 | const SignatureModel = Record({ 6 | alg: null, 7 | certs: [], 8 | digestAlgorithm: null, 9 | fileId: null, 10 | id: null, 11 | signingTime: null, 12 | status_verify: null, 13 | subject: null, 14 | }); 15 | 16 | const DefaultReducerState = Record({ 17 | entities: OrderedMap({}), 18 | packageSignResult: false, 19 | signedPackage: false, 20 | signingPackage: false, 21 | verifyingPackage: false, 22 | }); 23 | 24 | export default (signatures = new DefaultReducerState(), action) => { 25 | const { type, payload } = action; 26 | 27 | switch (type) { 28 | case PACKAGE_SIGN + START: 29 | return signatures 30 | .set("signedPackage", false) 31 | .set("signingPackage", true) 32 | .set("packageSignResult", false); 33 | 34 | case PACKAGE_SIGN + SUCCESS: 35 | return signatures 36 | .set("signedPackage", true) 37 | .set("signingPackage", false) 38 | .set("packageSignResult", payload.packageSignResult); 39 | 40 | case VERIFY_SIGNATURE + SUCCESS: 41 | return signatures.setIn(["entities", payload.fileId], arrayToMap(payload.signatureInfo, SignatureModel)); 42 | } 43 | 44 | return signatures; 45 | }; 46 | -------------------------------------------------------------------------------- /app/reducer/signers.ts: -------------------------------------------------------------------------------- 1 | import { REMOVE_ALL_CERTIFICATES, SELECT_SIGNER_CERTIFICATE } from "../constants"; 2 | 3 | const defaultSigners = { 4 | signer: "", 5 | }; 6 | 7 | export default (signers = defaultSigners, action) => { 8 | const { type, payload } = action; 9 | 10 | switch (type) { 11 | case SELECT_SIGNER_CERTIFICATE: 12 | return {...signers, signer: payload.selected}; 13 | case REMOVE_ALL_CERTIFICATES: 14 | return signers = defaultSigners; 15 | } 16 | 17 | return signers; 18 | }; 19 | -------------------------------------------------------------------------------- /app/resources/cryptoarm-gost.icns: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/cryptoarm-gost.icns -------------------------------------------------------------------------------- /app/resources/cryptoarm-gost.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/cryptoarm-gost.ico -------------------------------------------------------------------------------- /app/resources/cryptoarm-gost.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/cryptoarm-gost.png -------------------------------------------------------------------------------- /app/resources/cryptoarm-gost_1024.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/cryptoarm-gost_1024.png -------------------------------------------------------------------------------- /app/resources/fonts/material-design-icons/MaterialIcons-Regular.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/fonts/material-design-icons/MaterialIcons-Regular.eot -------------------------------------------------------------------------------- /app/resources/fonts/material-design-icons/MaterialIcons-Regular.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/fonts/material-design-icons/MaterialIcons-Regular.ttf -------------------------------------------------------------------------------- /app/resources/fonts/material-design-icons/MaterialIcons-Regular.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/fonts/material-design-icons/MaterialIcons-Regular.woff -------------------------------------------------------------------------------- /app/resources/fonts/material-design-icons/MaterialIcons-Regular.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/fonts/material-design-icons/MaterialIcons-Regular.woff2 -------------------------------------------------------------------------------- /app/resources/fonts/material-design-icons/README.md: -------------------------------------------------------------------------------- 1 | The recommended way to use the Material Icons font is by linking to the web font hosted on Google Fonts: 2 | 3 | ```html 4 | 6 | ``` 7 | 8 | Read more in our full usage guide: 9 | http://google.github.io/material-design-icons/#icon-font-for-the-web 10 | -------------------------------------------------------------------------------- /app/resources/fonts/material-design-icons/material-icons.css: -------------------------------------------------------------------------------- 1 | @font-face { 2 | font-family: 'Material Icons'; 3 | font-style: normal; 4 | font-weight: 400; 5 | src: url(MaterialIcons-Regular.eot); /* For IE6-8 */ 6 | src: local('Material Icons'), 7 | local('MaterialIcons-Regular'), 8 | url(MaterialIcons-Regular.woff2) format('woff2'), 9 | url(MaterialIcons-Regular.woff) format('woff'), 10 | url(MaterialIcons-Regular.ttf) format('truetype'); 11 | } 12 | 13 | .material-icons { 14 | font-family: 'Material Icons'; 15 | font-weight: normal; 16 | font-style: normal; 17 | font-size: 24px; /* Preferred icon size */ 18 | display: inline-block; 19 | line-height: 1; 20 | text-transform: none; 21 | letter-spacing: normal; 22 | word-wrap: normal; 23 | white-space: nowrap; 24 | direction: ltr; 25 | 26 | /* Support for all WebKit browsers. */ 27 | -webkit-font-smoothing: antialiased; 28 | /* Support for Safari and Chrome. */ 29 | text-rendering: optimizeLegibility; 30 | 31 | /* Support for Firefox. */ 32 | -moz-osx-font-smoothing: grayscale; 33 | 34 | /* Support for IE. */ 35 | font-feature-settings: 'liga'; 36 | } 37 | -------------------------------------------------------------------------------- /app/resources/fonts/roboto/Roboto-Bold.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/fonts/roboto/Roboto-Bold.eot -------------------------------------------------------------------------------- /app/resources/fonts/roboto/Roboto-Bold.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/fonts/roboto/Roboto-Bold.ttf -------------------------------------------------------------------------------- /app/resources/fonts/roboto/Roboto-Bold.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/fonts/roboto/Roboto-Bold.woff -------------------------------------------------------------------------------- /app/resources/fonts/roboto/Roboto-Bold.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/fonts/roboto/Roboto-Bold.woff2 -------------------------------------------------------------------------------- /app/resources/fonts/roboto/Roboto-Light.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/fonts/roboto/Roboto-Light.eot -------------------------------------------------------------------------------- /app/resources/fonts/roboto/Roboto-Light.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/fonts/roboto/Roboto-Light.ttf -------------------------------------------------------------------------------- /app/resources/fonts/roboto/Roboto-Light.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/fonts/roboto/Roboto-Light.woff -------------------------------------------------------------------------------- /app/resources/fonts/roboto/Roboto-Light.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/fonts/roboto/Roboto-Light.woff2 -------------------------------------------------------------------------------- /app/resources/fonts/roboto/Roboto-Medium.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/fonts/roboto/Roboto-Medium.eot -------------------------------------------------------------------------------- /app/resources/fonts/roboto/Roboto-Medium.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/fonts/roboto/Roboto-Medium.ttf -------------------------------------------------------------------------------- /app/resources/fonts/roboto/Roboto-Medium.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/fonts/roboto/Roboto-Medium.woff -------------------------------------------------------------------------------- /app/resources/fonts/roboto/Roboto-Medium.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/fonts/roboto/Roboto-Medium.woff2 -------------------------------------------------------------------------------- /app/resources/fonts/roboto/Roboto-Regular.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/fonts/roboto/Roboto-Regular.eot -------------------------------------------------------------------------------- /app/resources/fonts/roboto/Roboto-Regular.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/fonts/roboto/Roboto-Regular.ttf -------------------------------------------------------------------------------- /app/resources/fonts/roboto/Roboto-Regular.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/fonts/roboto/Roboto-Regular.woff -------------------------------------------------------------------------------- /app/resources/fonts/roboto/Roboto-Regular.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/fonts/roboto/Roboto-Regular.woff2 -------------------------------------------------------------------------------- /app/resources/fonts/roboto/Roboto-Thin.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/fonts/roboto/Roboto-Thin.eot -------------------------------------------------------------------------------- /app/resources/fonts/roboto/Roboto-Thin.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/fonts/roboto/Roboto-Thin.ttf -------------------------------------------------------------------------------- /app/resources/fonts/roboto/Roboto-Thin.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/fonts/roboto/Roboto-Thin.woff -------------------------------------------------------------------------------- /app/resources/fonts/roboto/Roboto-Thin.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/fonts/roboto/Roboto-Thin.woff2 -------------------------------------------------------------------------------- /app/resources/image/A43AE36C.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/image/A43AE36C.png -------------------------------------------------------------------------------- /app/resources/image/Flag_of_Russia.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/image/Flag_of_Russia.png -------------------------------------------------------------------------------- /app/resources/image/Flag_of_United_States.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/image/Flag_of_United_States.png -------------------------------------------------------------------------------- /app/resources/image/address_contact_icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/image/address_contact_icon.png -------------------------------------------------------------------------------- /app/resources/image/agreement_menu_icon.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 6 | 7 | 8 | 15 | 18 | 19 | 20 | 21 | -------------------------------------------------------------------------------- /app/resources/image/alert_error_icon.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 6 | 9 | 11 | 14 | 16 | 17 | 19 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | -------------------------------------------------------------------------------- /app/resources/image/alert_ok_icon.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 6 | 9 | 11 | 14 | 16 | 17 | 19 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | -------------------------------------------------------------------------------- /app/resources/image/alert_warning_icon.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 6 | 9 | 11 | 14 | 16 | 17 | 19 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | -------------------------------------------------------------------------------- /app/resources/image/cert_category_intermediate.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 6 | 7 | 16 | 20 | 21 | 22 | -------------------------------------------------------------------------------- /app/resources/image/cert_category_my.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 16 | 17 | 18 | 22 | 23 | 24 | -------------------------------------------------------------------------------- /app/resources/image/cert_category_other.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 17 | 18 | 20 | 27 | 29 | 30 | 31 | -------------------------------------------------------------------------------- /app/resources/image/cert_category_request.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 16 | 17 | 19 | 20 | 21 | -------------------------------------------------------------------------------- /app/resources/image/cert_category_token.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 16 | 17 | 19 | 20 | 21 | -------------------------------------------------------------------------------- /app/resources/image/cert_status_error.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 6 | 7 | 16 | 21 | 22 | 23 | -------------------------------------------------------------------------------- /app/resources/image/cert_status_ok.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 6 | 7 | 16 | 20 | 21 | 22 | -------------------------------------------------------------------------------- /app/resources/image/chain_1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/image/chain_1.png -------------------------------------------------------------------------------- /app/resources/image/chain_10.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/image/chain_10.png -------------------------------------------------------------------------------- /app/resources/image/chain_2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/image/chain_2.png -------------------------------------------------------------------------------- /app/resources/image/chain_3.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/image/chain_3.png -------------------------------------------------------------------------------- /app/resources/image/chain_4.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/image/chain_4.png -------------------------------------------------------------------------------- /app/resources/image/chain_5.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/image/chain_5.png -------------------------------------------------------------------------------- /app/resources/image/chain_6.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/image/chain_6.png -------------------------------------------------------------------------------- /app/resources/image/chain_7.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/image/chain_7.png -------------------------------------------------------------------------------- /app/resources/image/chain_8.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/image/chain_8.png -------------------------------------------------------------------------------- /app/resources/image/chain_9.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/image/chain_9.png -------------------------------------------------------------------------------- /app/resources/image/connect.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/image/connect.png -------------------------------------------------------------------------------- /app/resources/image/cryptoarm-gost.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/image/cryptoarm-gost.png -------------------------------------------------------------------------------- /app/resources/image/cryptoarm-gost.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 6 | 7 | 8 | 9 | 13 | 15 | 19 | 23 | 24 | 25 | -------------------------------------------------------------------------------- /app/resources/image/docmenu_arhiver.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 6 | 7 | 8 | 17 | 19 | 20 | 21 | 22 | -------------------------------------------------------------------------------- /app/resources/image/docmenu_decrypt.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 6 | 7 | 8 | 9 | 14 | 15 | 16 | 19 | 20 | 21 | -------------------------------------------------------------------------------- /app/resources/image/docmenu_encrypt.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 6 | 7 | 8 | 15 | 16 | 17 | 18 | -------------------------------------------------------------------------------- /app/resources/image/docmenu_remove.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 6 | 7 | 14 | 16 | 18 | 19 | 20 | -------------------------------------------------------------------------------- /app/resources/image/encrypt_type_icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/image/encrypt_type_icon.png -------------------------------------------------------------------------------- /app/resources/image/excel_type_icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/image/excel_type_icon.png -------------------------------------------------------------------------------- /app/resources/image/excel_type_icon.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 6 | 8 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | XLS 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | -------------------------------------------------------------------------------- /app/resources/image/facebook_icon.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 7 | 8 | 13 | 14 | 15 | -------------------------------------------------------------------------------- /app/resources/image/file_type_icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/image/file_type_icon.png -------------------------------------------------------------------------------- /app/resources/image/files/file_avi.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/image/files/file_avi.png -------------------------------------------------------------------------------- /app/resources/image/files/file_csr.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/image/files/file_csr.png -------------------------------------------------------------------------------- /app/resources/image/files/file_doc.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/image/files/file_doc.png -------------------------------------------------------------------------------- /app/resources/image/files/file_docx.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/image/files/file_docx.png -------------------------------------------------------------------------------- /app/resources/image/files/file_enc.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/image/files/file_enc.png -------------------------------------------------------------------------------- /app/resources/image/files/file_file.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/image/files/file_file.png -------------------------------------------------------------------------------- /app/resources/image/files/file_jpg.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/image/files/file_jpg.png -------------------------------------------------------------------------------- /app/resources/image/files/file_pdf.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/image/files/file_pdf.png -------------------------------------------------------------------------------- /app/resources/image/files/file_pfx.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/image/files/file_pfx.png -------------------------------------------------------------------------------- /app/resources/image/files/file_ppt.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/image/files/file_ppt.png -------------------------------------------------------------------------------- /app/resources/image/files/file_sig.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/image/files/file_sig.png -------------------------------------------------------------------------------- /app/resources/image/files/file_sig_any.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/image/files/file_sig_any.png -------------------------------------------------------------------------------- /app/resources/image/files/file_sig_error.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/image/files/file_sig_error.png -------------------------------------------------------------------------------- /app/resources/image/files/file_sig_ok.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/image/files/file_sig_ok.png -------------------------------------------------------------------------------- /app/resources/image/files/file_txt.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/image/files/file_txt.png -------------------------------------------------------------------------------- /app/resources/image/files/file_unknown.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/image/files/file_unknown.png -------------------------------------------------------------------------------- /app/resources/image/files/file_xls.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/image/files/file_xls.png -------------------------------------------------------------------------------- /app/resources/image/files/file_zip.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/image/files/file_zip.png -------------------------------------------------------------------------------- /app/resources/image/folder_shoose_icon.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 6 | 7 | 8 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | -------------------------------------------------------------------------------- /app/resources/image/geo_contact_icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/image/geo_contact_icon.png -------------------------------------------------------------------------------- /app/resources/image/geo_gray.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/image/geo_gray.png -------------------------------------------------------------------------------- /app/resources/image/google_icon.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /app/resources/image/help/cert_windows_chain.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/image/help/cert_windows_chain.png -------------------------------------------------------------------------------- /app/resources/image/help/cert_windows_using.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/image/help/cert_windows_using.png -------------------------------------------------------------------------------- /app/resources/image/help/decrypt_window.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/image/help/decrypt_window.png -------------------------------------------------------------------------------- /app/resources/image/help/encrypt_window_choose_cert.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/image/help/encrypt_window_choose_cert.png -------------------------------------------------------------------------------- /app/resources/image/help/encrypt_window_choose_files.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/image/help/encrypt_window_choose_files.png -------------------------------------------------------------------------------- /app/resources/image/help/encrypt_window_clear.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/image/help/encrypt_window_clear.png -------------------------------------------------------------------------------- /app/resources/image/help/license_window.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/image/help/license_window.png -------------------------------------------------------------------------------- /app/resources/image/help/license_window_modal.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/image/help/license_window_modal.png -------------------------------------------------------------------------------- /app/resources/image/help/main_window.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/image/help/main_window.png -------------------------------------------------------------------------------- /app/resources/image/help/main_window_menu.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/image/help/main_window_menu.png -------------------------------------------------------------------------------- /app/resources/image/help/menu_button.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/image/help/menu_button.png -------------------------------------------------------------------------------- /app/resources/image/help/sign_window_choose_cert.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/image/help/sign_window_choose_cert.png -------------------------------------------------------------------------------- /app/resources/image/help/sign_window_clear.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/image/help/sign_window_clear.png -------------------------------------------------------------------------------- /app/resources/image/help/sign_window_filling.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/image/help/sign_window_filling.png -------------------------------------------------------------------------------- /app/resources/image/help/sign_window_verify.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/image/help/sign_window_verify.png -------------------------------------------------------------------------------- /app/resources/image/help/user_guide.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/image/help/user_guide.png -------------------------------------------------------------------------------- /app/resources/image/icon_context_menu.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 6 | 7 | 8 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /app/resources/image/icon_fail.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 19 | 20 | 21 | -------------------------------------------------------------------------------- /app/resources/image/icon_ok.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 16 | 17 | 18 | -------------------------------------------------------------------------------- /app/resources/image/key.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 6 | 13 | 14 | -------------------------------------------------------------------------------- /app/resources/image/key_container_icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/image/key_container_icon.png -------------------------------------------------------------------------------- /app/resources/image/left-arrow.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /app/resources/image/licence_footer.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/image/licence_footer.png -------------------------------------------------------------------------------- /app/resources/image/logo_trusted.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/image/logo_trusted.png -------------------------------------------------------------------------------- /app/resources/image/logo_trusted.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 6 | 7 | 11 | 16 | 20 | 21 | 22 | -------------------------------------------------------------------------------- /app/resources/image/mail_contact_icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/image/mail_contact_icon.png -------------------------------------------------------------------------------- /app/resources/image/main.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/image/main.png -------------------------------------------------------------------------------- /app/resources/image/main_window_header.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/image/main_window_header.png -------------------------------------------------------------------------------- /app/resources/image/operation_status_error.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 6 | 7 | 9 | 13 | 14 | 15 | -------------------------------------------------------------------------------- /app/resources/image/operation_status_success.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 6 | 7 | 10 | 12 | 13 | 14 | -------------------------------------------------------------------------------- /app/resources/image/pdf_type_icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/image/pdf_type_icon.png -------------------------------------------------------------------------------- /app/resources/image/preloader.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/image/preloader.png -------------------------------------------------------------------------------- /app/resources/image/preloader.psd: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/image/preloader.psd -------------------------------------------------------------------------------- /app/resources/image/return-button.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | -------------------------------------------------------------------------------- /app/resources/image/service_category_cert.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 6 | 7 | 16 | 20 | 21 | 22 | -------------------------------------------------------------------------------- /app/resources/image/service_category_connect.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 6 | 7 | 12 | 19 | 20 | 21 | -------------------------------------------------------------------------------- /app/resources/image/services/dss.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/image/services/dss.png -------------------------------------------------------------------------------- /app/resources/image/services/dss_key.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 6 | 7 | 12 | 20 | 21 | 22 | -------------------------------------------------------------------------------- /app/resources/image/services/megafon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/image/services/megafon.png -------------------------------------------------------------------------------- /app/resources/image/services/svs.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/image/services/svs.png -------------------------------------------------------------------------------- /app/resources/image/sign_menu_icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/image/sign_menu_icon.png -------------------------------------------------------------------------------- /app/resources/image/sign_type_icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/image/sign_type_icon.png -------------------------------------------------------------------------------- /app/resources/image/status_cert_fail_icon.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 19 | 20 | 21 | -------------------------------------------------------------------------------- /app/resources/image/status_cert_ok_icon.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 16 | 17 | 18 | -------------------------------------------------------------------------------- /app/resources/image/tray.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/image/tray.ico -------------------------------------------------------------------------------- /app/resources/image/tray.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/image/tray.png -------------------------------------------------------------------------------- /app/resources/image/tray_mac.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/image/tray_mac.png -------------------------------------------------------------------------------- /app/resources/image/tray_nix.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/image/tray_nix.png -------------------------------------------------------------------------------- /app/resources/image/tree_element.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /app/resources/image/trusted-esign.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/image/trusted-esign.png -------------------------------------------------------------------------------- /app/resources/image/trusted-esign.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 6 | 7 | 8 | 9 | 10 | 14 | 16 | 20 | 24 | 25 | 26 | 27 | -------------------------------------------------------------------------------- /app/resources/image/twitter_icon.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 7 | 8 | 9 | 16 | 17 | 18 | 19 | -------------------------------------------------------------------------------- /app/resources/image/vk_icon.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 7 | 8 | 20 | 21 | 22 | -------------------------------------------------------------------------------- /app/resources/image/warning.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 6 | 7 | 8 | 15 | 16 | 17 | 18 | -------------------------------------------------------------------------------- /app/resources/image/word_type_icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/image/word_type_icon.png -------------------------------------------------------------------------------- /app/resources/image/word_type_icon.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 6 | 8 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | DOC 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | -------------------------------------------------------------------------------- /app/resources/image/zip_type_icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/image/zip_type_icon.png -------------------------------------------------------------------------------- /app/resources/js/jquery.visible.js: -------------------------------------------------------------------------------- 1 | (function($){ 2 | 3 | /** 4 | * Copyright 2012, Digital Fusion 5 | * Licensed under the MIT license. 6 | * http://teamdf.com/jquery-plugins/license/ 7 | * 8 | * @author Sam Sehnert 9 | * @desc A small plugin that checks whether elements are within 10 | * the user visible viewport of a web browser. 11 | * only accounts for vertical position, not horizontal. 12 | */ 13 | $.fn.visible = function(partial,hidden){ 14 | 15 | var $t = $(this).eq(0), 16 | t = $t.get(0), 17 | $w = $(window), 18 | viewTop = $w.scrollTop(), 19 | viewBottom = viewTop + $w.height(), 20 | _top = $t.offset().top, 21 | _bottom = _top + $t.height(), 22 | compareTop = partial === true ? _bottom : _top, 23 | compareBottom = partial === true ? _top : _bottom, 24 | clientSize = hidden === true ? t.offsetWidth * t.offsetHeight : true; 25 | 26 | return !!clientSize && ((compareBottom <= viewBottom) && (compareTop >= viewTop)); 27 | }; 28 | 29 | })(jQuery); -------------------------------------------------------------------------------- /app/resources/js/jquery.visible.min.js: -------------------------------------------------------------------------------- 1 | /*! jQuery visible 1.0.0 teamdf.com/jquery-plugins | teamdf.com/jquery-plugins/license */ 2 | (function(d){d.fn.visible=function(e,i){var a=d(this).eq(0),f=a.get(0),c=d(window),g=c.scrollTop();c=g+c.height();var b=a.offset().top,h=b+a.height();a=e===true?h:b;b=e===true?b:h;return!!(i===true?f.offsetWidth*f.offsetHeight:true)&&b<=c&&a>=g}})(jQuery); 3 | -------------------------------------------------------------------------------- /app/resources/preloader_index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | Trusted-eSign 7 | 8 | 9 | 10 | 11 | 12 |
    13 | 14 |
    15 | 16 | 17 | 18 | -------------------------------------------------------------------------------- /app/resources/ssl/addCA.linux.sh: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | #Add directory for license 3 | mkdir "/etc/opt/Trusted" 4 | mkdir "/etc/opt/Trusted/Trusted eSign" 5 | chmod 777 "/etc/opt/Trusted/Trusted eSign" 6 | 7 | CUR_DIR=`dirname $0` 8 | certPath=${CUR_DIR}/root.pem 9 | certificateName="eSign Local CA" 10 | 11 | echo -e "certificateName: ${certificateName}" 12 | echo -e "certPath: ${certPath}" 13 | 14 | # Firefox 15 | PROGRAM_NAME=firefox 16 | PROGRAM_PATH=$(which "$PROGRAM_NAME") 17 | 18 | BROWSER_PATH="" 19 | 20 | while true; do 21 | if [ -L "$PROGRAM_PATH" ] ;then 22 | PROGRAM_PATH=$(readlink -f "$PROGRAM_PATH") 23 | else 24 | if [ -d "$PROGRAM_PATH" ] ;then 25 | BROWSER_PATH="$PROGRAM_PATH" 26 | break 27 | else 28 | BROWSER_PATH=$(dirname "$PROGRAM_PATH") 29 | break 30 | fi 31 | fi 32 | done 33 | 34 | if [ -n "$BROWSER_PATH" ] ;then 35 | if [ -d "$BROWSER_PATH/browser" ] ;then 36 | echo "$BROWSER_PATH" 37 | else 38 | BROWSER_PATH="" 39 | fi 40 | fi 41 | 42 | if [ -z "$BROWSER_PATH" ] ;then 43 | if [ -d "/usr/lib/$PROGRAM_NAME/browser" ] ;then 44 | BROWSER_PATH="/usr/lib/$PROGRAM_NAME" 45 | echo "/usr/lib/$PROGRAM_NAME" 46 | fi 47 | if [ -d "/usr/lib64/$PROGRAM_NAME/browser" ] ;then 48 | BROWSER_PATH="/usr/lib64/$PROGRAM_NAME" 49 | echo "/usr/lib64/$PROGRAM_NAME" 50 | fi 51 | fi 52 | 53 | if [ -n "$BROWSER_PATH" ] ;then 54 | echo "Firefox was found" 55 | 56 | cp $CUR_DIR/firefox/esign-firefox-preferences.cfg "$BROWSER_PATH/" 57 | if [ -d "$BROWSER_PATH/defaults/pref" ] ;then 58 | cp $CUR_DIR/firefox/esign-firefox-preferences.js "$BROWSER_PATH/defaults/pref/" 59 | else 60 | if [ -d "$BROWSER_PATH/defaults/preferences" ] ;then 61 | cp $CUR_DIR/firefox/esign-firefox-preferences.js "$BROWSER_PATH/defaults/preferences/" 62 | fi 63 | fi 64 | else 65 | echo "Firfeox cannot be found. $certificateName certificate not installed" 66 | fi 67 | -------------------------------------------------------------------------------- /app/resources/ssl/addCA.win.bat: -------------------------------------------------------------------------------- 1 | @echo off 2 | 3 | if not exist "%UserProfile%\AppData\Local\Trusted\Trusted eSign" mkdir "%UserProfile%\AppData\Local\Trusted\Trusted eSign" 4 | 5 | 6 | setlocal 7 | 8 | @echo Installing "eSign Local CA" certificate 9 | certutil -addstore -Enterprise root "%~dp0\root.pem" 10 | 11 | REM ####Current user 12 | setlocal ENABLEDELAYEDEXPANSION 13 | set certpath=%~dp0root.pem 14 | set certName=eSign Local CA 15 | 16 | FOR /D %%P IN ("%appdata%\Mozilla\Firefox\Profiles\*") DO ( 17 | "%~dp0certutil\win32\certutil.exe" -D -n "!certName!" -d sql:"%%P" 18 | "%~dp0certutil\win32\certutil.exe" -D -n "!certName!" -d dbm:"%%P" 19 | 20 | "%~dp0certutil\win32\certutil.exe" -A -n "!certName!" -i "%certpath%" -t "C,c,c", -d sql:"%%P" 21 | "%~dp0certutil\win32\certutil.exe" -A -n "!certName!" -i "%certpath%" -t "C,c,c", -d dbm:"%%P" 22 | ) 23 | setlocal DISABLEDELAYEDEXPANSION 24 | 25 | 26 | REM #### eof 27 | exit /B 0 28 | -------------------------------------------------------------------------------- /app/resources/ssl/cert.pem: -------------------------------------------------------------------------------- 1 | -----BEGIN CERTIFICATE----- 2 | MIID9jCCAt6gAwIBAgIJAOM8AcTRqV+8MA0GCSqGSIb3DQEBCwUAME8xCzAJBgNV 3 | BAYTAlJVMREwDwYDVQQIDAhNYXJpaiBFbDEUMBIGA1UEBwwLWW9zaGthci1PbGEx 4 | FzAVBgNVBAMMDmVTaWduIExvY2FsIENBMB4XDTE4MDgxNjEyNDQzMloXDTE5MDgx 5 | NjEyNDQzMlowZDELMAkGA1UEBhMCUlUxETAPBgNVBAgMCE1hcmlqIEVsMRQwEgYD 6 | VQQHDAtZb3Noa2FyLU9sYTEVMBMGA1UECgwMVHJ1c3RlZCBQbHVzMRUwEwYDVQQD 7 | DAx0cnVzdGVkLnBsdXMwggEiMA0GCSqGSIb3DQEBAQUAA4IBDwAwggEKAoIBAQC0 8 | TxE2g9ESW68aJMdMDEQjITUUN3/v9cRlq8xO4rFe7eHJXDd4Va1v4WUcktok9hP+ 9 | xnHc4DDDKbKwgEsZ9MROr3XPr2K/Pgfh5horMZc4za14Iw7a5/btZ2nXZi5VJain 10 | gTFYqT3ZPGVWMMxxMPLY5B77CFnsbxc2NnEv6GkPPd3p3+p+dTOKoANCMfBKhWXa 11 | crEGYfx4YKqCb6Fcbmxt8ch4mxaBIwJkJ1I4zyFcJRlcxWdEX4O1eQqrh+/Yx/Ww 12 | ZAFT/4PWiqzAQIqR7B76s2NT0sYeWNRe9jUoj9katO6VcjyPT7z6iZx5sFHvVqQf 13 | Ny+Ay2aq7F3ZE3A6GNGRAgMBAAGjgb8wgbwwGgYDVR0RBBMwEYIJbG9jYWxob3N0 14 | hwR/AAABMB0GA1UdDgQWBBQjnB6cNqBdI3wQnCwCfSdt6D2knTB/BgNVHSMEeDB2 15 | gBTrmlSFGyHIy90PdeRrkobLtZNeI6FTpFEwTzELMAkGA1UEBhMCUlUxETAPBgNV 16 | BAgMCE1hcmlqIEVsMRQwEgYDVQQHDAtZb3Noa2FyLU9sYTEXMBUGA1UEAwwOZVNp 17 | Z24gTG9jYWwgQ0GCCQD4eOAY2h5UfDANBgkqhkiG9w0BAQsFAAOCAQEAM2SEDCKu 18 | FWUp31cVvjdzBQMOqP5veLLsY2vOkG6tw5H70iUi1jcfM1v9ZQ0jrHjrVKY1Kyos 19 | 68Qs9Lvi2JYSSRE/GOMeOBxEE6fmX8bAwgIwKE9wrjDpA2kF483yCqS3CItZ85gL 20 | TXAzcW49SKTdZ4ddY00azkKrT9Wdbf7SOZLlw0Jzc2kp436vh+NPrN3/udZy2FVM 21 | ecXq9X/D4igkKTQnqf5IDsW0FUOudK/ePDt9E9f2+mobRBVlkv2W83Fi3WP4g0Jg 22 | Tv8lg9+GSIAMFlUcQ3MlQmuYOaf1aaejXQBK1WobWn9vIHTeQathMaM3XAVJPkUt 23 | LgTmaIYO0C6zMg== 24 | -----END CERTIFICATE----- 25 | -------------------------------------------------------------------------------- /app/resources/ssl/certutil/osx/certutil: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/ssl/certutil/osx/certutil -------------------------------------------------------------------------------- /app/resources/ssl/certutil/osx/libfreebl3.dylib: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/ssl/certutil/osx/libfreebl3.dylib -------------------------------------------------------------------------------- /app/resources/ssl/certutil/osx/libgtest1.dylib: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/ssl/certutil/osx/libgtest1.dylib -------------------------------------------------------------------------------- /app/resources/ssl/certutil/osx/libgtestutil.dylib: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/ssl/certutil/osx/libgtestutil.dylib -------------------------------------------------------------------------------- /app/resources/ssl/certutil/osx/libnspr4.dylib: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/ssl/certutil/osx/libnspr4.dylib -------------------------------------------------------------------------------- /app/resources/ssl/certutil/osx/libnss3.dylib: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/ssl/certutil/osx/libnss3.dylib -------------------------------------------------------------------------------- /app/resources/ssl/certutil/osx/libnssckbi.dylib: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/ssl/certutil/osx/libnssckbi.dylib -------------------------------------------------------------------------------- /app/resources/ssl/certutil/osx/libnssdbm3.dylib: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/ssl/certutil/osx/libnssdbm3.dylib -------------------------------------------------------------------------------- /app/resources/ssl/certutil/osx/libnssutil3.dylib: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/ssl/certutil/osx/libnssutil3.dylib -------------------------------------------------------------------------------- /app/resources/ssl/certutil/osx/libplc4.dylib: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/ssl/certutil/osx/libplc4.dylib -------------------------------------------------------------------------------- /app/resources/ssl/certutil/osx/libplds4.dylib: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/ssl/certutil/osx/libplds4.dylib -------------------------------------------------------------------------------- /app/resources/ssl/certutil/osx/libsmime3.dylib: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/ssl/certutil/osx/libsmime3.dylib -------------------------------------------------------------------------------- /app/resources/ssl/certutil/osx/libsoftokn3.dylib: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/ssl/certutil/osx/libsoftokn3.dylib -------------------------------------------------------------------------------- /app/resources/ssl/certutil/osx/libssl3.dylib: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/ssl/certutil/osx/libssl3.dylib -------------------------------------------------------------------------------- /app/resources/ssl/certutil/osx/new_card.tmpl: -------------------------------------------------------------------------------- 1 | Reader name: ${reader} 2 | ATR: ${atr} 3 | 4 | ```js 5 | { 6 | "cards": [{ 7 | "atr": "${atr}", 8 | "name": "Token name", 9 | "driver": "${driver}" 10 | }], 11 | "drivers": [{ 12 | "id": "${driver}", 13 | "name": "Driver name", 14 | "file": { 15 | "windows": "path/to/pkcs11.dll", 16 | "osx": "path/to/pkcs11.dylib" 17 | } 18 | }] 19 | } 20 | ``` 21 | 22 | [Smart card ATR parsing ${atr}](https://smartcard-atr.appspot.com/parse?ATR=${atr}) -------------------------------------------------------------------------------- /app/resources/ssl/certutil/win32/certutil.exe: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/ssl/certutil/win32/certutil.exe -------------------------------------------------------------------------------- /app/resources/ssl/certutil/win32/freebl3.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/ssl/certutil/win32/freebl3.dll -------------------------------------------------------------------------------- /app/resources/ssl/certutil/win32/libnspr4.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/ssl/certutil/win32/libnspr4.dll -------------------------------------------------------------------------------- /app/resources/ssl/certutil/win32/libplc4.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/ssl/certutil/win32/libplc4.dll -------------------------------------------------------------------------------- /app/resources/ssl/certutil/win32/libplds4.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/ssl/certutil/win32/libplds4.dll -------------------------------------------------------------------------------- /app/resources/ssl/certutil/win32/nss3.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/ssl/certutil/win32/nss3.dll -------------------------------------------------------------------------------- /app/resources/ssl/certutil/win32/nssckbi.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/ssl/certutil/win32/nssckbi.dll -------------------------------------------------------------------------------- /app/resources/ssl/certutil/win32/nssdbm3.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/ssl/certutil/win32/nssdbm3.dll -------------------------------------------------------------------------------- /app/resources/ssl/certutil/win32/nssutil3.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/ssl/certutil/win32/nssutil3.dll -------------------------------------------------------------------------------- /app/resources/ssl/certutil/win32/smime3.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/ssl/certutil/win32/smime3.dll -------------------------------------------------------------------------------- /app/resources/ssl/certutil/win32/softokn3.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/ssl/certutil/win32/softokn3.dll -------------------------------------------------------------------------------- /app/resources/ssl/certutil/win32/sqlite3.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/ssl/certutil/win32/sqlite3.dll -------------------------------------------------------------------------------- /app/resources/ssl/certutil/win32/ssl3.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/app/resources/ssl/certutil/win32/ssl3.dll -------------------------------------------------------------------------------- /app/resources/ssl/firefox/esign-firefox-preferences.js: -------------------------------------------------------------------------------- 1 | 2 | pref('general.config.obscure_value', 0); 3 | pref('general.config.filename', 'esign-firefox-preferences.cfg'); 4 | -------------------------------------------------------------------------------- /app/resources/ssl/key.pem: -------------------------------------------------------------------------------- 1 | -----BEGIN RSA PRIVATE KEY----- 2 | MIIEowIBAAKCAQEAtE8RNoPREluvGiTHTAxEIyE1FDd/7/XEZavMTuKxXu3hyVw3 3 | eFWtb+FlHJLaJPYT/sZx3OAwwymysIBLGfTETq91z69ivz4H4eYaKzGXOM2teCMO 4 | 2uf27Wdp12YuVSWop4ExWKk92TxlVjDMcTDy2OQe+whZ7G8XNjZxL+hpDz3d6d/q 5 | fnUziqADQjHwSoVl2nKxBmH8eGCqgm+hXG5sbfHIeJsWgSMCZCdSOM8hXCUZXMVn 6 | RF+DtXkKq4fv2Mf1sGQBU/+D1oqswECKkewe+rNjU9LGHljUXvY1KI/ZGrTulXI8 7 | j0+8+omcebBR71akHzcvgMtmquxd2RNwOhjRkQIDAQABAoIBAAJHLXR+3dlZhzDR 8 | XiM71HCNLtp+iQNDG6QdM4ubmZoVb1DX9WtzyaksM9bUlCT7Zu1FHJMp0fPlRvir 9 | 5kcBrKlB1j81fA3mfrr/6Ty6d6qkDpkB+GITpC8Dq3apN9SjkSnsm+7+1GU2OiGI 10 | pEyZzbenyixpwpkWHjj1HyD30rv6iq42tbQAWoDNqsx7iNpAKAEjkxFwkXleeHmp 11 | NNFx5hRpzryLDulVJc1Vb8hOi0a/q9q6CrAe2EY++CmWlbMRRV7dP8LmFSvDp1nr 12 | YcWcf/kesF/X7xXDm0/hPjG+AmdPZfPqBWD35NhqF3rBnCX8jIPT4KxYuR9aFznB 13 | avcQkEECgYEA5fJn5RgM6pXA+YzwfGDsh5X6wRW2/yTUd8S2S+ZfxckcA2uIKSR6 14 | ZGANIur1H63U4ciClOq/l+U9LWfWuD4w44lJw50Yfnbzbih6eGpFP6f3epCBtxfG 15 | dIDHVeDA79Hzw2982D2EKVDQSuwclIlJt8xbaAyEa0QKuOWdErCE/A0CgYEAyLzp 16 | 0xfbwwibJEBIddV/b8yjKIPzDgqZO1uA6kiyC1b081HGa2LS7t88d7szLc2OfBgA 17 | 1qDhWE6c0fYqoq/uvgOqH/zTNkVdZHHTxSvldHcDLTxrXGnp2TmHRj3Z/yMYlbfm 18 | JsvWJYABFLEa4WNciUUiHfR2wn1is9bRqNPtFpUCgYA6eMaUieYW7NeyXXV1m0vq 19 | OmgWG0h6XsosXnggmsc1yyr1b62jEKSSy53riCWm1ZQxicQyy/LGVEOXPTVrilzy 20 | LyHzvQnSdrr2AxMJdbSAOF0E7KQfg8syKuEFZG6LTS8YPkxXzGTEAMnGk329A6Ac 21 | Pbnsnmo5wIadd73WV86pLQKBgCdQ+OsjbSOR9/DttkN+AWvAROSWk3BYmxKJJYK9 22 | okGeUnOlvJsjy/SFPK6mt6ts609a1C81a22EWCq3cDpVAwmsZhHFzwh+JYCa2sNv 23 | iY16EeE2SEDdbbPiFKCpVJ0oHpSUZDuNCPBnVc7bsUwbzfAE3l3Hl8sYC9D1bjMG 24 | 7xTRAoGBAImZXcESB24sfGRX/fI5MCym/KlRbmphovJUR0++QvNRqjj36go1sn2C 25 | ksP7ldKO7mLR+mCkS2QfZztOpVwS7Q+iQ/gotUwpLA9MaZmvjRitZqBrtD7TcbGJ 26 | yTmPVoq37xd8W2QZbHBz1JHca5dtYlSnkK+amhfvl3LlCuBVwEKb 27 | -----END RSA PRIVATE KEY----- 28 | -------------------------------------------------------------------------------- /app/resources/ssl/osx_firefox.sh: -------------------------------------------------------------------------------- 1 | # check if Firefox is running 2 | if pgrep -x "firefox" > /dev/null 3 | then 4 | echo "Reopen Firefox" 5 | osascript <<'END' 6 | quit app "Firefox" 7 | repeat 8 | if application "Firefox" is not running then exit repeat 9 | delay 3 10 | end repeat 11 | open app "Firefox" 12 | END 13 | fi 14 | -------------------------------------------------------------------------------- /app/resources/ssl/root.pem: -------------------------------------------------------------------------------- 1 | -----BEGIN CERTIFICATE----- 2 | MIIECTCCAvGgAwIBAgIJAPh44BjaHlR8MA0GCSqGSIb3DQEBCwUAME8xCzAJBgNV 3 | BAYTAlJVMREwDwYDVQQIDAhNYXJpaiBFbDEUMBIGA1UEBwwLWW9zaGthci1PbGEx 4 | FzAVBgNVBAMMDmVTaWduIExvY2FsIENBMB4XDTE4MDgxNjEyNDM1OVoXDTIzMDgx 5 | NjEyNDM1OVowTzELMAkGA1UEBhMCUlUxETAPBgNVBAgMCE1hcmlqIEVsMRQwEgYD 6 | VQQHDAtZb3Noa2FyLU9sYTEXMBUGA1UEAwwOZVNpZ24gTG9jYWwgQ0EwggEiMA0G 7 | CSqGSIb3DQEBAQUAA4IBDwAwggEKAoIBAQD6oDDptWjnGvppslFdfi5reBZwiFoV 8 | 3C2j7fshsPgUbZV27z/mToTS4JVWLx6SZ6tThNkQc63WnmfEodKoKJsfSrIRqiIV 9 | dxPRFNkHkATuO3j8RCljO8yFl1H4ffcmLxdfEn5ZaRzjGOkm1ZO9t20L3541p5Xj 10 | q7knZUB1luAW3ptKg/Q49zL36ZqhczaosKgtYAz8TyS1vHm4qFVGfWq0aw4SliwN 11 | r0NFPBHJz7410OGUScAnvb2/BQwEQb79HZ5/C7QO2VNwV42n03y9iLZ77Utg9gUU 12 | ODceaZCQ7NO3x2U1TX5K4WXv4hoxhjju3omMDU7TEoErvnILQVItqOSDAgMBAAGj 13 | gecwgeQwDAYDVR0TBAUwAwEB/zAdBgNVHQ4EFgQU65pUhRshyMvdD3Xka5KGy7WT 14 | XiMwfwYDVR0jBHgwdoAU65pUhRshyMvdD3Xka5KGy7WTXiOhU6RRME8xCzAJBgNV 15 | BAYTAlJVMREwDwYDVQQIDAhNYXJpaiBFbDEUMBIGA1UEBwwLWW9zaGthci1PbGEx 16 | FzAVBgNVBAMMDmVTaWduIExvY2FsIENBggkA+HjgGNoeVHwwNAYDVR0fBC0wKzAp 17 | oCegJYYjaHR0cHM6Ly9sb2NhbGhvc3Q6NDA0MC9jcmxfcm9vdC5wZW0wDQYJKoZI 18 | hvcNAQELBQADggEBAIkwW5ikqOdqWh/pvDQUj0GHg2bz/la+ZaS5rUVLRiiobGIC 19 | B1vB4yTlf6rV6JJQbTy30toCkU3t7Eo6kfUOq/7CfwmzvojLhTGDbyjkrL0sFyOU 20 | u8a8AEvvtFoyKlI1fAkYAk9re39SpTXkztMw3qJ04IeA3SbYe+7sTwREUgNewBO2 21 | eKukVjtOUF2oD+3b72LrAwNH/7pKrDkspx1cUwuVOUzIt1Ry8n834Wuz7Z1VZVdW 22 | 4OQtbVDMyhB+NbeZ1990YCizbzlyu1edY5zZXywLk7stEtfg+/7lP5N0lIK2wZCv 23 | uWgjM2v9suhADhJwjW9nngvgdgmKyPumd2dxW5k= 24 | -----END CERTIFICATE----- 25 | -------------------------------------------------------------------------------- /app/selectors/crlsSelectors.ts: -------------------------------------------------------------------------------- 1 | import { createSelector } from "reselect"; 2 | import { mapToArr } from "../utils"; 3 | 4 | export const crlsGetter = (state: any) => state.crls.entities; 5 | export const filtersGetter = (state: any) => state.filters; 6 | 7 | export const filteredCrlsSelector = createSelector(crlsGetter, filtersGetter, (crls, filters) => { 8 | const { searchValue } = filters; 9 | const search = searchValue.toLowerCase(); 10 | let arrCrls = mapToArr(crls); 11 | 12 | arrCrls = arrCrls.sort((a, b) => { 13 | const aCrlIN = a.issuerFriendlyName.toLowerCase(); 14 | const bCrlIN = b.issuerFriendlyName.toLowerCase(); 15 | 16 | if (aCrlIN < bCrlIN) { 17 | return -1; 18 | } 19 | 20 | if (aCrlIN > bCrlIN) { 21 | return 1; 22 | } 23 | 24 | return 0; 25 | }); 26 | 27 | return arrCrls.filter((crl: any) => { 28 | return ( 29 | crl.hash.toLowerCase().match(search) || 30 | crl.issuerFriendlyName.toLowerCase().match(search) || 31 | crl.lastUpdate.toLowerCase().match(search) || 32 | crl.nextUpdate.toLowerCase().match(search) || 33 | crl.signatureAlgorithm.toLowerCase().match(search) 34 | ); 35 | }); 36 | }); 37 | -------------------------------------------------------------------------------- /app/selectors/documentsSelector.ts: -------------------------------------------------------------------------------- 1 | import { createSelector } from "reselect"; 2 | import { 3 | ALL, ENCRYPTED, SIGNED, 4 | } from "../constants"; 5 | 6 | export const documentsGetter = (state) => state.documents.entities; 7 | export const filtersGetter = (state) => state.filters; 8 | 9 | export const filteredDocumentsSelector = createSelector(documentsGetter, filtersGetter, (documents, filters) => { 10 | const { dateFrom, dateTo, filename, sizeFrom, sizeTo, types } = filters.documents; 11 | 12 | return documents.filter((document: any) => { 13 | return document.fullpath.match(filename) && 14 | (sizeFrom ? document.filesize >= sizeFrom : true) && 15 | (sizeTo ? document.filesize <= sizeTo : true) && 16 | (dateFrom ? (new Date(document.mtime)).getTime() >= (new Date(dateFrom)).getTime() : true) && 17 | (dateTo ? (new Date(document.mtime)).getTime() <= (new Date(dateTo.setHours(23, 59, 59, 999))).getTime() : true) && 18 | ( 19 | types[ENCRYPTED] && document.extname === ".enc" || 20 | types[SIGNED] && document.extname === ".sig" || 21 | ( 22 | !types[ENCRYPTED] && !types[SIGNED] 23 | ) 24 | ); 25 | }); 26 | }); 27 | 28 | export const stateSelector = (state: any) => state.documents; 29 | export const entitiesSelector = createSelector(stateSelector, (state) => state.entities); 30 | export const selectionSelector = createSelector(stateSelector, (state) => state.selected.toArray()); 31 | export const selectedDocumentsSelector = createSelector(entitiesSelector, selectionSelector, (entities, selection) => 32 | selection.map((uid: any) => entities.get(uid)), 33 | ); 34 | -------------------------------------------------------------------------------- /app/server/constants.ts: -------------------------------------------------------------------------------- 1 | export const CONNECTION = "connection"; 2 | export const CONNECT = "connect"; 3 | export const DISCONNECT = "disconnect"; 4 | 5 | export const SIGN = "sign"; 6 | export const VERIFY = "verify"; 7 | export const ENCRYPT = "encrypt"; 8 | export const DECRYPT = "decrypt"; 9 | 10 | export const SIGNED = "signed"; 11 | export const VERIFIED = "verified"; 12 | export const ENCRYPTED = "encrypted"; 13 | export const DECRYPTED = "decrypted"; 14 | 15 | export const UPLOADED = "uploaded"; 16 | 17 | export const CANCELLED = "cancelled"; 18 | export const UNAVAILABLE = "unavailable"; 19 | export const ERROR = "error"; 20 | -------------------------------------------------------------------------------- /app/server/http.ts: -------------------------------------------------------------------------------- 1 | import * as http from "http"; 2 | 3 | export default http.createServer().listen(8040); 4 | -------------------------------------------------------------------------------- /app/server/https.ts: -------------------------------------------------------------------------------- 1 | import * as fs from "fs"; 2 | import * as https from "https"; 3 | import { DEFAULT_PATH } from "../constants"; 4 | 5 | const privateKey = fs.readFileSync(DEFAULT_PATH + "/ssl/key.pem", "utf8"); 6 | const certificate = fs.readFileSync(DEFAULT_PATH + "/ssl/cert.pem", "utf8"); 7 | 8 | const credentials = {key: privateKey, cert: certificate}; 9 | 10 | export default https.createServer(credentials, (req, res) => { 11 | res.writeHead(200, {"Content-Type": "text/plain"}); 12 | res.end("CryptoARM server is alive and working\n"); 13 | }).listen(4040); 14 | -------------------------------------------------------------------------------- /app/server/socketIO.ts: -------------------------------------------------------------------------------- 1 | import * as socketIO from "socket.io"; 2 | import https from "./https"; 3 | 4 | const io = socketIO.listen(https); 5 | 6 | export default io; 7 | -------------------------------------------------------------------------------- /app/service/megafon/constants.ts: -------------------------------------------------------------------------------- 1 | // SIGN ENDPOINT 2 | export const SIGN_DOCUMENT = "SIGN_DOCUMENT"; 3 | export const SIGN_TEXT = "SIGN_TEXT"; 4 | export const SIGN_HASH = "SIGN_HASH"; 5 | export const SIGN_XML = "SIGN_XML"; 6 | export const MULTIPLY_SIGN = "MULTIPLY_SIGN"; 7 | export const DECRYPT_DOC = "DECRYPT_DOC"; 8 | export const VERIFY = "VERIFY"; 9 | 10 | // STATUS ENDPOINT 11 | export const GET_SIGN_STATUS = "GET_SIGN_STATUS"; 12 | export const GET_AUTH_STATUS = "GET_AUTH_STATUS"; 13 | export const GET_DECRYPT_STATUS = "GET_DECRYPT_STATUS"; 14 | 15 | export const SIGN_URI = "https://msign.megafon.ru/mes-ws/sign"; 16 | export const STATUS_URI = "https://msign.megafon.ru/mes-ws/status"; 17 | 18 | export const MEGAFON = "MEGAFON"; 19 | export const MEGAFON_NAME = "МЭП Мегафон"; 20 | -------------------------------------------------------------------------------- /app/service/megafon/endpoint/status.ts: -------------------------------------------------------------------------------- 1 | // tslint:disable:object-literal-sort-keys 2 | 3 | /* 4 | Получение статусов операций при pull нотификации. 5 | Сервис доступен по адресу https://msign.megafon.ru/mes-ws/status?wsdl 6 | */ 7 | 8 | import { fromJS, Map } from "immutable"; 9 | import xml2js from "xml2js"; 10 | import { GET_SIGN_STATUS } from "../constants"; 11 | import { IGetSignStatus } from "../types"; 12 | 13 | const builder = new xml2js.Builder(); 14 | const partnerId = "digt"; 15 | 16 | const mapTemplateRequest = Map(fromJS({ 17 | "soapenv:Envelope": { 18 | "$": { 19 | "xmlns:soapenv": "http://schemas.xmlsoap.org/soap/envelope/", 20 | "xmlns:ws": "http://megalabs.ru/mes/ws-api", 21 | }, 22 | "soapenv:Header": {}, 23 | "soapenv:Body": {}, 24 | }, 25 | })); 26 | 27 | const mapGetSignStatusRequest = Map(fromJS({ 28 | "ws:partner_id": { 29 | _: partnerId, 30 | }, 31 | "ws:transaction_id": { 32 | _: "?", 33 | }, 34 | })); 35 | 36 | export const buildXML = (template: "GET_SIGN_STATUS", inputParams: IGetSignStatus) => { 37 | switch (template) { 38 | case GET_SIGN_STATUS: 39 | const sstatusBody = createGetSignStatusBody(mapGetSignStatusRequest, inputParams); 40 | return builder.buildObject(mapTemplateRequest.setIn(["soapenv:Envelope", "soapenv:Body", "ws:getSignStatusRequest"], sstatusBody).toJS()); 41 | 42 | default: 43 | return ""; 44 | } 45 | }; 46 | 47 | const createGetSignStatusBody = (body: Map, inputParams: IGetSignStatus) => { 48 | return body 49 | .setIn(["ws:transaction_id", "_"], inputParams.transaction_id); 50 | }; 51 | -------------------------------------------------------------------------------- /app/store/configureStore.development.ts: -------------------------------------------------------------------------------- 1 | import { routerMiddleware } from "react-router-redux"; 2 | import { applyMiddleware, compose, createStore } from "redux"; 3 | import { createLogger } from "redux-logger"; 4 | import thunk from "redux-thunk"; 5 | import history from "../history"; 6 | import randomId from "../middlewares/randomId"; 7 | import reducer from "../reducer/index"; 8 | import preloadedState from "./preloadedState"; 9 | 10 | const router = routerMiddleware(history); 11 | 12 | const composeEnhancers = 13 | typeof window === "object" && 14 | window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__ ? 15 | window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__({ 16 | // Specify extension’s options like name, actionsBlacklist, actionsCreators, serialize... 17 | }) : compose 18 | 19 | const logger = createLogger({ 20 | level: "info", 21 | collapsed: true, 22 | }); 23 | 24 | const enhancer = composeEnhancers( 25 | applyMiddleware(logger, thunk, router, randomId), 26 | ); 27 | 28 | const store = createStore(reducer, preloadedState, enhancer); 29 | 30 | if (module.hot) { 31 | module.hot.accept("../reducer", () => 32 | store.replaceReducer(require("../reducer")), // eslint-disable-line global-require 33 | ); 34 | } 35 | 36 | export default store; 37 | -------------------------------------------------------------------------------- /app/store/configureStore.production.ts: -------------------------------------------------------------------------------- 1 | import { routerMiddleware } from "react-router-redux"; 2 | import { applyMiddleware, createStore } from "redux"; 3 | import thunk from "redux-thunk"; 4 | import history from "../history"; 5 | import randomId from "../middlewares/randomId"; 6 | import reducer from "../reducer/index"; 7 | import preloadedState from "./preloadedState"; 8 | 9 | const router = routerMiddleware(history); 10 | const enhancer = applyMiddleware(thunk, router, randomId); 11 | 12 | const store = createStore(reducer, preloadedState, enhancer); 13 | 14 | export default store; 15 | -------------------------------------------------------------------------------- /app/store/index.ts: -------------------------------------------------------------------------------- 1 | import developmentConfigureStore from "./configureStore.development"; 2 | import productionConfigureStore from "./configureStore.production"; 3 | 4 | export default ( 5 | process.env.NODE_ENV === "production" 6 | ? productionConfigureStore 7 | : developmentConfigureStore 8 | ); 9 | -------------------------------------------------------------------------------- /app/table.global.css: -------------------------------------------------------------------------------- 1 | .Table { 2 | width: 100%; 3 | margin-top: 15px; 4 | } 5 | .headerRow { 6 | border-bottom: 1px solid #e0e0e0; 7 | font-size: 1rem; 8 | } 9 | .evenRow, 10 | .oddRow { 11 | border-bottom: 1px solid #e0e0e0; 12 | font-size: 0.9rem; 13 | } 14 | .oddRow { 15 | background-color: #fafafa; 16 | } 17 | .foundEvent { 18 | background-color: PapayaWhip; 19 | } 20 | .selectedEvent { 21 | background-color: lightgrey; 22 | } 23 | .headerColumn { 24 | text-transform: none; 25 | } 26 | .exampleColumn { 27 | white-space: nowrap; 28 | overflow: hidden; 29 | text-overflow: ellipsis; 30 | } 31 | 32 | .checkboxLabel { 33 | margin-left: .5rem; 34 | } 35 | .checkboxLabel:first-of-type { 36 | margin-left: 0; 37 | } 38 | 39 | .noRows { 40 | position: absolute; 41 | top: 0; 42 | bottom: 0; 43 | left: 0; 44 | right: 0; 45 | display: flex; 46 | align-items: center; 47 | justify-content: center; 48 | font-size: 1em; 49 | color: #bdbdbd; 50 | } 51 | 52 | .navigationToolbar { 53 | bottom: 20px !important; 54 | right: 30px !important; 55 | position: fixed !important; 56 | padding: 10px !important; 57 | background-color: rgba(255,255,255,0.8) !important; 58 | z-index: 1000 !important; 59 | } 60 | 61 | .ReactVirtualized__Grid, .ReactVirtualized__Table__headerColumn, .ReactVirtualized__Table__row { 62 | outline: none; 63 | } 64 | -------------------------------------------------------------------------------- /app/winstonLogger.ts: -------------------------------------------------------------------------------- 1 | import * as winston from "winston"; 2 | import { APP_LOG_FILE } from "./constants"; 3 | 4 | const logger = winston.createLogger({ 5 | format: winston.format.combine( 6 | winston.format.timestamp(), 7 | winston.format.json(), 8 | ), 9 | level: "debug", 10 | transports: [ 11 | new winston.transports.File({ 12 | filename: APP_LOG_FILE, 13 | maxsize: 4 * 4096, 14 | }), 15 | ], 16 | }); 17 | 18 | if (process.env.NODE_ENV !== "production") { 19 | logger.add(new winston.transports.Console({ 20 | format: winston.format.simple(), 21 | })); 22 | } 23 | 24 | export default logger; 25 | -------------------------------------------------------------------------------- /demo/demo-socket.io/.gitignore: -------------------------------------------------------------------------------- 1 | /node_modules 2 | .DS_Store 3 | /client/dist 4 | 5 | -------------------------------------------------------------------------------- /demo/demo-socket.io/client/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | Demo 6 | 7 | 8 | 9 |

    Work with Socket.io demo

    10 | 11 |

    For view events open web console in developer tools your browser

    12 | 13 |
    14 | 15 |
    16 | 1. sign - send files collection for sign in cryptoarm 17 |
    18 | 19 |
    20 | 21 |
    22 | 23 |
    24 | 25 |
    26 | 2. verify - send files collection for verify in cryptoarm 27 |
    28 | 29 |
    30 | 31 |
    32 | 33 |
    34 | 35 |
    36 | 3. encrypt - send files collection for encrypt in cryptoarm 37 |
    38 | 39 |
    40 | 41 |
    42 | 43 |
    44 | 45 |
    46 | 4. decrypt - send files collection for decrypt in cryptoarm 47 |
    48 | 49 |
    50 | 51 |
    52 | 53 |
    54 | 55 |
    56 | 5. unavailable - send unavailable file for sign in cryptoarm 57 |
    58 | 59 |
    60 | 61 |
    62 | 63 |
    64 | 65 | 66 | 67 | 68 | 69 | 70 | -------------------------------------------------------------------------------- /demo/demo-socket.io/gulpfile.js: -------------------------------------------------------------------------------- 1 | "use strict"; 2 | const source = require('vinyl-source-stream'); 3 | const buffer = require('vinyl-buffer'); 4 | const gulp = require('gulp'); 5 | const gutil = require('gulp-util'); 6 | const sourcemaps = require('gulp-sourcemaps'); 7 | const browserify = require('browserify'); 8 | const babelify = require('babelify'); 9 | const colors = require('colors'); 10 | 11 | gulp.task('default', () => { 12 | let buildPath; 13 | let destPath; 14 | 15 | buildPath = `./client/src`; 16 | destPath = `./client/dist`; 17 | 18 | // script 19 | return browserify(`${buildPath}/app.js`) 20 | .transform(babelify, { 21 | presets: ["es2015"] 22 | }) 23 | .bundle() 24 | .pipe(source('app.js')) 25 | .pipe(buffer()) 26 | .pipe(sourcemaps.init({loadMaps: true})) 27 | .pipe(sourcemaps.write('./')) 28 | .pipe(gulp.dest(`${destPath}`)); 29 | }); 30 | -------------------------------------------------------------------------------- /demo/demo-socket.io/package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "demo-socket.io", 3 | "version": "1.0.0", 4 | "description": "", 5 | "main": "index.js", 6 | "scripts": { 7 | "test": "echo \"Error: no test specified\" && exit 1" 8 | }, 9 | "author": "", 10 | "dependencies": { 11 | "express": "^4.14.0", 12 | "socket.io": "^1.6.0", 13 | "socket.io-client": "^1.6.0", 14 | "vinyl-buffer": "^1.0.0", 15 | "vinyl-source-stream": "^1.1.0" 16 | }, 17 | "devDependencies": { 18 | "babel-preset-es2015": "^6.9.0", 19 | "babelify": "^7.3.0", 20 | "browserify": "^13.0.1", 21 | "colors": "^1.1.2", 22 | "gulp": "^3.9.1", 23 | "gulp-sourcemaps": "^1.6.0" 24 | } 25 | } 26 | -------------------------------------------------------------------------------- /demo/demo-socket.io/resources/file1.txt: -------------------------------------------------------------------------------- 1 | 123 2 | -------------------------------------------------------------------------------- /demo/demo-socket.io/resources/file2.txt: -------------------------------------------------------------------------------- 1 | 12345 -------------------------------------------------------------------------------- /demo/demo-socket.io/resources/file3.txt: -------------------------------------------------------------------------------- 1 | 12345 2 | -------------------------------------------------------------------------------- /demo/demo-socket.io/resources/file5.enc: -------------------------------------------------------------------------------- 1 | -----BEGIN CMS----- 2 | MIAGCSqGSIb3DQEHA6CAMIACAQAxggGtMIIBqQIBADCBkDCBgjELMAkGA1UEBhMC 3 | QVUxEzARBgNVBAgMClNvbWUtU3RhdGUxGjAYBgNVBAoMEU9yZ2FuaXphdGlvbiBu 4 | YW1lMR4wHAYDVQQDDBVUZXN0IFJTQSBTSEEtMjU2IGNlcnQxIjAgBgkqhkiG9w0B 5 | CQEWE2V4YW1wbGVAZXhhbXBsZS5vcmcCCQD+DOSX22eDiTANBgkqhkiG9w0BAQEF 6 | AASCAQBAMmsHpLGa4fSlV2IVDMlJIs8OMGLL35fDnHtQI6SzB5X6c22axVxWzCKA 7 | pQuRrrTSP20LqLriXD7S+37vAFa3J29rF/cfa7jhHtEIdwJY0LOeFpZDfyVFICYm 8 | asy/NGpWon5bs1XIDXNBR2nBCvTskWnwojaQLum1vVRXKgMMkYJDQP5rOQFTXM+P 9 | Ud3RlEVKPsHqKoPpC2MIz1EN/OFji8JeghaLG4UwGq6EvXTNVXQUCoW63R8JIC94 10 | MP3hVet3XjqMS3+RWMjm5rJ1UuJ8IWl/V65RsNFm6gDo42zHvjnL9PvwOb3ACR0r 11 | iPCIv4lCWgtB9nO8UJ9RGjnnZfgNMIAGCSqGSIb3DQEHATAUBggqhkiG9w0DBwQI 12 | wLEtne8RAC+ggAQISOdEjGLs7EUAAAAAAAAAAAAA 13 | -----END CMS----- 14 | -------------------------------------------------------------------------------- /demo/demo-socket.io/resources/file7.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/demo/demo-socket.io/resources/file7.pdf -------------------------------------------------------------------------------- /demo/demo-socket.io/ssl/cert.pem: -------------------------------------------------------------------------------- 1 | -----BEGIN CERTIFICATE----- 2 | MIIFhTCCA22gAwIBAgIJAPAW2hwNc1z/MA0GCSqGSIb3DQEBCwUAMFkxCzAJBgNV 3 | BAYTAlJVMRMwEQYDVQQIDApTb21lLVN0YXRlMSEwHwYDVQQKDBhJbnRlcm5ldCBX 4 | aWRnaXRzIFB0eSBMdGQxEjAQBgNVBAMMCWxvY2FsaG9zdDAeFw0xODAyMjYwOTMx 5 | MDhaFw0xOTAyMjYwOTMxMDhaMFkxCzAJBgNVBAYTAlJVMRMwEQYDVQQIDApTb21l 6 | LVN0YXRlMSEwHwYDVQQKDBhJbnRlcm5ldCBXaWRnaXRzIFB0eSBMdGQxEjAQBgNV 7 | BAMMCWxvY2FsaG9zdDCCAiIwDQYJKoZIhvcNAQEBBQADggIPADCCAgoCggIBAJrM 8 | lRtVRPH8f85+urHYihKmBRvVeToWhGrLvW5zHV5OPAIv3ngYX2jm+5/ViFfyXTFL 9 | h0FO6Zhf0cXhVV0671U5RwbhXjWdwJ/UGGNeK76iBeok8aoX/fdFilxp8hXJzZxT 10 | jBKOLv+7VJkD7CazyRj4zTLhlfTs0nbwyK2l+/20bueAiiK7oDn7sSr9f3AbXwoU 11 | TEXw7yC95pxT9mlnLjvPvWgrSxJhF9VyyrqqmBBGfGVwfoJ/O9aT6YsI6rpWKc8f 12 | QhE/jrcypiIXB81rsC6t/DEHllpWZON5RYQh8jO3zi57iRcluFw//6oG8H/nI7PB 13 | i4QNQTv/BzYopoGE70+ZN11iIx4aFC7/iqDOgvH7KRJaCZXt/ZOEQKuCqlQIa/GE 14 | 81/J9MG0j5uZIWYpI+cd/AWtrtAEqctOxyQuBSK8HKLZxiWmr3eF1volKD9KXAWo 15 | 0+ZWO5Mq47KCK8CM54Am0QaWVvxCqnGcG47jFLRxgjL2cgntip33Rj9a+gGHivN0 16 | lnaLlzlziGI8g8pKqEZeve3b9bRLa6VgPRAxAT1u8evt6PE43pYdSPelbdnubRcC 17 | hDvx+ALPT66eikei0pJGx8AEMsD3UVeWuBqpmgdi2JdMkZngYUakqm17xzWLeSL9 18 | UhccQpi+2juxfP4PaQG0EtipEncXu3Oa3tiTBqPXAgMBAAGjUDBOMB0GA1UdDgQW 19 | BBTqsN81AhxZF+YFV5RJ6kH1IYoGTTAfBgNVHSMEGDAWgBTqsN81AhxZF+YFV5RJ 20 | 6kH1IYoGTTAMBgNVHRMEBTADAQH/MA0GCSqGSIb3DQEBCwUAA4ICAQB9pvMCWZ/B 21 | JN2Xq5POomzp9lbebOUfJi8EYZyC4GEcaHKfAah2L3FNc2Q23NfwQQA7TZbfV7rE 22 | IoKHDlEfu/bv05E2G5kcLdJ69HjoFi3Ie6m+pKXKHEsqeDoqUaH0YpIvlu58kJ3r 23 | 5px4+ikG1fgH7BOYV1DdZJb21X8DQhYCMR+MQxzDOvA8Ecen/AieaHwcp6dIsAsn 24 | o1Is4tbj9JRiy3wTByWN7XqqHxNe9HFliwNkbht2tHsKFNiWwiM4esGMOy2dpaQs 25 | AsoWtoNEij4jBajFPmiRbsDSI8jh5ZGbITLFzjpAlwmOSRVL349nXVyQLbOU0Ztd 26 | FfMTAZ8GHmofgMtJSL3ftaERWXH6W3taINczKbbrHeJI33dpERL4oN9Vsi/efOcX 27 | RAyoFIiPBVSFXeCIViIGc4aiVAt6BNjlHS8JGdJoLOAI+gqL8p3O0j9+HBZyAxF1 28 | r/oYS0kbOBpo6EWkyMuWpx4FJ5yW8N/8aSU8LOlS3zqSGiFlkqgf5ijrlLxXfhvX 29 | 1oPAYq5VkxaZilt83MftnTwJt+mawwtxw2u1DssEHpjp8olcYexyxMkhYMfdKk3L 30 | HAXgw4jkspDeemZgkB9QAd68RzqroNrhtVAEPl8fuWequWMSmq9mSroIK8UTbOO0 31 | rQX/rslbfHJ5OrN7g1N3MbfWablyf9RGLA== 32 | -----END CERTIFICATE----- 33 | -------------------------------------------------------------------------------- /docs/Руководство пользователя.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/docs/Руководство пользователя.pdf -------------------------------------------------------------------------------- /docs/Руководство программиста.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Trusted-eSign/esign/72f2ae49c3aef529d2901c22b26db49c4033bb28/docs/Руководство программиста.pdf -------------------------------------------------------------------------------- /product.json: -------------------------------------------------------------------------------- 1 | { 2 | "nameShort": "Trusted eSign", 3 | "nameLong": "Trusted eSign", 4 | "applicationName": "trusted-esign" 5 | } 6 | -------------------------------------------------------------------------------- /tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "jsx": "react", 4 | "target": "ES6", 5 | "allowSyntheticDefaultImports": true, 6 | "module": "commonjs", 7 | //"noEmitOnError": true, 8 | "strict": true, 9 | "allowJs": true, 10 | "pretty": true, 11 | "sourceMap": false, 12 | "noImplicitAny": true, 13 | "moduleResolution": "node", 14 | "typeRoots": [ 15 | "node_modules/@types" 16 | ], 17 | "rootDir": "app", 18 | "outDir": "tmp" 19 | }, 20 | "exclude": [ 21 | "node_modules", 22 | "app/node_modules" 23 | ], 24 | "externalTranspiler": { 25 | "name": "babel", 26 | "options": { 27 | "presets": [ 28 | ["env", { 29 | "targets": { "node": 6 }, 30 | "useBuiltIns": true 31 | }], 32 | "es2015", 33 | "stage-0", 34 | "react", 35 | "react-hmre" 36 | ], 37 | "plugins": ["add-module-exports", "dynamic-import-webpack"], 38 | "env": { 39 | "production": { 40 | "presets": ["react-optimize"], 41 | "plugins": ["babel-plugin-dev-expression"] 42 | }, 43 | "development": { 44 | "plugins": [ 45 | "transform-class-properties", 46 | "transform-es2015-classes", 47 | "react-hot-loader/babel" 48 | ] 49 | } 50 | } 51 | } 52 | } 53 | } 54 | -------------------------------------------------------------------------------- /tslint.json: -------------------------------------------------------------------------------- 1 | { 2 | "extends": "tslint:recommended", 3 | "rules": { 4 | "no-reference": false, 5 | "member-access": false, 6 | "only-arrow-functions": [ 7 | false 8 | ], 9 | "max-line-length": [ 10 | true, 11 | 220 12 | ] 13 | } 14 | } 15 | -------------------------------------------------------------------------------- /types/modal.d.ts: -------------------------------------------------------------------------------- 1 | interface JQuery { 2 | closeModal(): void; 3 | leanModal(): void; 4 | openModal(complete?: any, dismissible?: boolean): void; 5 | } 6 | -------------------------------------------------------------------------------- /webpack.config.base.js: -------------------------------------------------------------------------------- 1 | /** 2 | * Base webpack config used across other specific configs 3 | */ 4 | 5 | import path from 'path'; 6 | import webpack from 'webpack'; 7 | import { dependencies as externals } from './app/package.json'; 8 | 9 | export default { 10 | externals: Object.keys(externals || {}), 11 | 12 | module: { 13 | rules: [{ 14 | test: /\.tsx?$/, 15 | exclude: /node_modules/, 16 | use: { 17 | loader: 'babel-loader' 18 | } 19 | // @TODO: Waiting until awesome-typescript-loader can throw 20 | // warnings instead of errors. This makes sure that the dev 21 | // build will work even with typescript errors 22 | // use: { 23 | // loader: 'awesome-typescript-loader', 24 | // options: { 25 | // silent: true, 26 | // useBabel: true, 27 | // useCache: true 28 | // } 29 | // } 30 | }] 31 | }, 32 | 33 | output: { 34 | path: path.join(__dirname, 'app'), 35 | filename: 'bundle.js', 36 | // https://github.com/webpack/webpack/issues/1114 37 | libraryTarget: 'commonjs2' 38 | }, 39 | 40 | /** 41 | * Determine the array of extensions that should be used to resolve modules. 42 | */ 43 | resolve: { 44 | extensions: ['.js', '.jsx', '.ts', '.tsx', '.json'], 45 | modules: [ 46 | path.join(__dirname, 'app'), 47 | 'node_modules', 48 | ], 49 | }, 50 | 51 | plugins: [ 52 | new webpack.NamedModulesPlugin(), 53 | ], 54 | }; 55 | -------------------------------------------------------------------------------- /webpack.config.eslint.js: -------------------------------------------------------------------------------- 1 | require('babel-register'); 2 | 3 | module.exports = require('./webpack.config.renderer.dev'); 4 | -------------------------------------------------------------------------------- /webpack.config.main.prod.js: -------------------------------------------------------------------------------- 1 | /** 2 | * Webpack config for production electron main process 3 | */ 4 | 5 | import webpack from 'webpack'; 6 | import merge from 'webpack-merge'; 7 | import BabiliPlugin from 'babili-webpack-plugin'; 8 | import { BundleAnalyzerPlugin } from 'webpack-bundle-analyzer'; 9 | import baseConfig from './webpack.config.base'; 10 | 11 | export default merge.smart(baseConfig, { 12 | devtool: 'source-map', 13 | 14 | target: 'electron-main', 15 | 16 | entry: ['babel-polyfill', './app/main.development'], 17 | 18 | // 'main.js' in root 19 | output: { 20 | path: __dirname, 21 | filename: './app/main.js' 22 | }, 23 | 24 | plugins: [ 25 | /** 26 | * Babli is an ES6+ aware minifier based on the Babel toolchain (beta) 27 | */ 28 | new BabiliPlugin(), 29 | 30 | new BundleAnalyzerPlugin({ 31 | analyzerMode: process.env.OPEN_ANALYZER === 'true' ? 'server' : 'disabled', 32 | openAnalyzer: process.env.OPEN_ANALYZER === 'true' 33 | }), 34 | 35 | /** 36 | * Create global constants which can be configured at compile time. 37 | * 38 | * Useful for allowing different behaviour between development builds and 39 | * release builds 40 | * 41 | * NODE_ENV should be production so that modules do not perform certain 42 | * development checks 43 | */ 44 | new webpack.DefinePlugin({ 45 | 'process.env.NODE_ENV': JSON.stringify(process.env.NODE_ENV || 'production'), 46 | 'process.env.DEBUG_PROD': JSON.stringify(process.env.DEBUG_PROD || 'false') 47 | }) 48 | ], 49 | 50 | /** 51 | * Disables webpack processing of __dirname and __filename. 52 | * If you run the bundle in node.js it falls back to these values of node.js. 53 | * https://github.com/webpack/webpack/issues/2010 54 | */ 55 | node: { 56 | __dirname: false, 57 | __filename: false 58 | }, 59 | }); 60 | --------------------------------------------------------------------------------