Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Do secure browser interface [PROC 512] #1

Open
wants to merge 187 commits into
base: release
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
187 commits
Select commit Hold shift + click to select a range
65de9e0
changes..
May 10, 2024
53a4ffb
build command for win..
May 10, 2024
49dd8a5
added display added ..
May 10, 2024
31b9bce
phase 2 changes...
May 13, 2024
636adb3
add configure comp..
May 14, 2024
ac648ce
key blocker changes...
May 15, 2024
1d66dc3
add instruction page...
May 16, 2024
0717646
add links ..
May 16, 2024
40caf60
final changes...
May 16, 2024
013d335
added configure changes..
May 17, 2024
338a659
change protocol schema..
May 17, 2024
c5214e0
add logs.
May 17, 2024
dc48dca
add logs..
May 17, 2024
9eb564e
test delete.
May 17, 2024
cab98fb
missed logs..
May 17, 2024
0eac4f4
added display info..
May 17, 2024
696d78c
add error check..
May 17, 2024
b4b3ebc
add display checks..
May 17, 2024
7f45434
added more shirtcut keys..
May 17, 2024
e2b94d1
configure notification..
May 17, 2024
a9b4ef0
added logs..
May 17, 2024
f9a8e32
add escape character..
May 17, 2024
6742640
slash issues..
May 17, 2024
e8f2ccb
revert slash issue.
May 17, 2024
94f8141
add slash issue.
May 17, 2024
62c408e
command change..
May 17, 2024
69001f5
add notification flag..
May 17, 2024
37fa193
notification logs..
May 17, 2024
35aa4fc
notification logsss..
May 17, 2024
6357905
test start button added..
May 17, 2024
83c2ab7
changes..
May 17, 2024
00c3076
add notification logs..
May 17, 2024
b9e0f8e
notification logs..
May 17, 2024
771ca8e
notification logs..
May 17, 2024
b6253ad
notification logs..
May 17, 2024
f766d90
notification logs..
May 17, 2024
7a0ad2c
change drive link...
May 20, 2024
70b5395
upadte new version of app.
May 22, 2024
67bbac4
update electron app..
May 22, 2024
0c23452
adding recurring mechanism..
May 23, 2024
fab075d
changes...
May 23, 2024
412b81f
revert..
May 23, 2024
9f13470
changes...
May 23, 2024
9087731
add recurring events..
May 24, 2024
ae500ed
changes..
May 24, 2024
e7914e1
remove setinterval...
May 24, 2024
e663a21
recurring change..
May 24, 2024
4e3b7c1
changes...
May 24, 2024
4e03e76
changes.....
May 24, 2024
fe0e397
revert changes..
May 24, 2024
a4d1347
prompt user permission...
May 27, 2024
701aa6b
add public url to donwload .exe app.
May 27, 2024
080b2ea
add oader with hybrid approach.
Jun 3, 2024
1ac9324
changes configure page..
Jun 3, 2024
807c39f
set checked unchecked apps..
Jun 3, 2024
4cdb7d7
remove display apps.
Jun 3, 2024
a59e829
retry mechanism..
Jun 3, 2024
6956ee0
kill command intitae..
Jun 3, 2024
ba42440
kill process..
Jun 3, 2024
3058cb2
success ate added..
Jun 3, 2024
db38a42
extra checks..
Jun 3, 2024
0ef80cb
extra checkss..
Jun 3, 2024
e192003
changes..
Jun 3, 2024
a86f394
changess...
Jun 3, 2024
7367d90
added logs..
Jun 3, 2024
e48fd14
added extra checks..
Jun 3, 2024
4a2d6a0
changes...
Jun 3, 2024
478e3f9
chnages...
Jun 3, 2024
cb42366
changess...
Jun 3, 2024
962fdd9
changes...
Jun 3, 2024
0856652
revert some changes..
Jun 3, 2024
11ac138
safety checks addedd.
Jun 3, 2024
adfddb6
changes..
Jun 3, 2024
fee7993
checks addedd.
Jun 3, 2024
8d57f0f
changes..
Jun 3, 2024
62def8f
changess added to phase 6.
Jun 4, 2024
15a477d
logs added..
Jun 4, 2024
11abbfa
toast enable values..
Jun 4, 2024
9560dd3
phase 6 checks..
Jun 4, 2024
59bfc26
changes...
Jun 5, 2024
e33affa
chabges..
Jun 5, 2024
58b9139
changes...
Jun 5, 2024
d78ac1a
changes..
Jun 5, 2024
e554e39
changes..
Jun 6, 2024
4ca7ade
double dpeendecy issue...
Jun 6, 2024
ac0d9c2
dev changes..
Jun 6, 2024
4fa0549
ui changes...
Jun 6, 2024
dd5b1a2
fix..
Jun 7, 2024
99505c8
ui changes..
Jun 7, 2024
d158c09
add fallback cases on secure browser app...
Jun 11, 2024
7265772
fallback cases...
Jun 11, 2024
d1c7f58
bug fixes...
Jun 11, 2024
feb716d
added any desk software to build...
Jun 13, 2024
cad5057
added disable state for re verify button..
Jun 14, 2024
91349df
change in parse condition..
Jun 14, 2024
2eed559
parseing changes..
Jun 14, 2024
e849f26
parseing changes..
Jun 14, 2024
9051d38
parseing changes..
Jun 14, 2024
7bb17fc
parseing changes..
Jun 14, 2024
f523fb4
decypt changes...
Jun 17, 2024
a3ed42a
commit changes...
Jun 17, 2024
90653a1
changes...
Jun 17, 2024
7cf8ab4
encypt changes...
Jun 17, 2024
56b3f38
changes...
Jun 17, 2024
d4abf9d
pasring info..
Jun 18, 2024
9288cd0
decrypt algorithm added...
Jun 18, 2024
9716fc7
decyption algo...
Jun 18, 2024
89ba5f9
decyption logic changes...
Jun 18, 2024
210ae27
decypt changes....
Jun 19, 2024
dc46bff
changes...
Jun 19, 2024
59e9de9
changes...
Jun 19, 2024
6280441
add new folder...
Jun 19, 2024
e2472a1
changes...
Jun 19, 2024
8ec5729
changes...
Jun 19, 2024
ef6fe7c
changes...
Jun 19, 2024
8e0e16f
decruption algo...
Jun 21, 2024
73abb50
url changes...
Jun 21, 2024
ba6f406
changes...
Jun 21, 2024
61e93bf
changes...
Jun 21, 2024
06e99ba
loader changes...
Jun 21, 2024
a624a82
return issue..
Jun 21, 2024
c3130f6
block finger gestures...
Jun 24, 2024
1044f8d
changes...
Jun 24, 2024
fb94522
disable four finger gesture...
Jun 24, 2024
79d18c8
block getures in start of the test..
Jun 24, 2024
19ecdfc
blocking actions...
Jun 24, 2024
9109564
revert changes...
Jun 24, 2024
6a5780a
added logs for secure browser inteface....
Jun 24, 2024
66df0c1
add email id as global key...
Jun 24, 2024
cdfa08f
order changes...
Jun 24, 2024
fd9a077
added testname as global key..
Jun 24, 2024
9788184
CR points....
Jun 28, 2024
8a1fe32
re order info...
Jun 28, 2024
ccb8687
remove HELP ...
Jun 28, 2024
9aacbb6
added identification of custom protocol...
Jul 1, 2024
e986274
changes...
Jul 1, 2024
427e96f
custom protocol schema...
Jul 1, 2024
7dfc96d
changes...
Jul 1, 2024
1e3b4a7
cr points...
Jul 2, 2024
c59bdfc
remove info....
Jul 2, 2024
433ac84
remove footer stickeness...
Jul 2, 2024
c8c07b2
pat points...
Jul 2, 2024
5cdc3f2
help underline changes..
Jul 2, 2024
0deee3f
remove footer...
Jul 2, 2024
d919ba8
added favicon...
Jul 4, 2024
1c6ff59
footer rmeoved from test route page..
Jul 4, 2024
947a580
CR points..
Jul 7, 2024
1f678d2
cr points...
Jul 8, 2024
ffe40ca
bug fix..
Jul 8, 2024
e4ef16a
remove font copyright..
Jul 8, 2024
a9a5331
cr points...
Jul 8, 2024
2c16f70
cr points..
Jul 8, 2024
694e239
changes...
Jul 8, 2024
fbf4a21
revert env changees...
Jul 8, 2024
2138746
added script url in env file,..
Jul 8, 2024
8401e31
revert testing flags (ms-teams , brave.)
Jul 9, 2024
4b64d3f
font-family changes...
Jul 9, 2024
e0b260e
product remove help cta..
Jul 10, 2024
6196bbd
product change..
Jul 10, 2024
cc16c8d
CR points...
Jul 18, 2024
baa4d7c
configure eslint and resolve all issues..
Jul 18, 2024
564aed6
remove some dependecies..
Jul 18, 2024
d42ae81
readme updated..
Jul 18, 2024
3a0c4e5
linux check added...
Aug 13, 2024
4d85b36
downloadable links for win linux...
Aug 14, 2024
3ea5758
non debian ubutu system changes....
Aug 30, 2024
c0f1424
system check bug fixes...
Aug 30, 2024
95fe67b
button width changes..
Aug 30, 2024
1307dcd
add zendesk link...
Sep 2, 2024
56508fc
changes...
Sep 3, 2024
3eeea3d
bug fix..
Sep 3, 2024
8fa0bcf
pat points..
Sep 4, 2024
3b0f644
pat points..
Sep 4, 2024
106036e
pat changes..
Sep 4, 2024
25147dd
open url in new tab..
Sep 4, 2024
8a8e7d1
remove quotes..
Sep 4, 2024
4df2856
add spacing..
Sep 4, 2024
3eb4e70
Merge pull request #3 from doselect/PROC-571
manishbharti02 Sep 5, 2024
fedefc0
changes in macos check
khushbooshaw779 Sep 13, 2024
809a94c
defensive checks
khushbooshaw779 Sep 13, 2024
cfb585c
macos download link
khushbooshaw779 Sep 20, 2024
f2d7eea
dmg build
khushbooshaw779 Sep 23, 2024
452bebb
remove unrequired codes
khushbooshaw779 Sep 29, 2024
70e5a93
Merge pull request #4 from doselect/PROC-622
khushbooshaw779 Oct 3, 2024
0579d56
footer distortion fixes...
Oct 21, 2024
4291f77
Merge branch 'master' of github.com:doselect/do-secrure-browser-inter…
Oct 21, 2024
9d02fe5
added github template.. (#5)
manishbharti02 Dec 30, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions .babelrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
{
"presets": ["@babel/preset-env", "@babel/preset-react"]
}
6 changes: 6 additions & 0 deletions .env
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
NODE_ENV = development
REACT_APP_DOWNLOAD_LINK_WIN = https://dev-doselect-static.s3.ap-southeast-1.amazonaws.com/secure-browser/Doselect+Secure+Browser.exe
REACT_APP_DOWNLOAD_LINK_LINUX=https://dev-doselect-static.s3.ap-southeast-1.amazonaws.com/secure-browser/Doselect+Secure+Browser.deb
REACT_APP_DOWNLOAD_LINK_MACOS=https://dev-doselect-static.s3.ap-southeast-1.amazonaws.com/secure-browser/Doselect+Secure+Browser.dmg
REACT_APP_UBA_BEACON_URL= https://test.collector.infoedge.com/uba
REACT_APP_UB_SCRIPT_URL= https://assets.central.dev.sg1.chsh.in/scripts/ub_v1.16.min.js
18 changes: 18 additions & 0 deletions .eslintrc.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
{
"parser": "@babel/eslint-parser",
"parserOptions": {
"requireConfigFile": false,
"babelOptions": {
"presets": ["@babel/preset-react"]
}
},
"extends": ["react-app", "airbnb", "plugin:prettier/recommended"],
"plugins": ["react", "jsx-a11y", "import", "react-hooks", "prettier"],
"rules": {
"react/jsx-filename-extension": [1, { "extensions": [".js", ".jsx"] }],
"react/react-in-jsx-scope": "off",
"react/prop-types": "off",
"react/no-array-index-key": "warn",
"prettier/prettier": ["error", { "singleQuote": true, "printWidth": 80 }]
}
}
32 changes: 32 additions & 0 deletions .github/PULL_REQUEST_TEMPLATE.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
## Description

<!-- Provide a brief summary of the changes and their impact. Ensure clear touchpoints are included. -->

## Checklist

Please ensure the following standards are met before submitting the PR:

- [ ] Code adheres to standard coding practices.
- [ ] Code has been reviewed for potential optimization and clean structure.
- [ ] Tests have been written or updated to cover the changes.
- [ ] Documentation has been updated (if applicable).

## Bundle Analyzer

- [ ] A screenshot of the bundle analyzer output is attached for size and optimization verification.

## Functional Logic

- [ ] If this PR involves functional logic, an additional reviewer with relevant expertise has been requested.

## Jira Task Integration

- [ ] A code review subtask has been created in Jira, and CR time is accounted for in the task estimates.

## Reviewer Comments

- [ ] If unable to check all coding practices due to constraints, comments have been added to the PR explaining which areas remain unchecked.

## Related Issues

<!-- Link to issues here. Example: Closes #CS-2045 -->
7 changes: 1 addition & 6 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -11,12 +11,7 @@
# production
/build

# misc
.DS_Store
.env.local
.env.development.local
.env.test.local
.env.production.local


npm-debug.log*
yarn-debug.log*
Expand Down
5 changes: 5 additions & 0 deletions .prettierrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
{
"singleQuote": true,
"semi": true,
"tabWidth": 2
}
12 changes: 12 additions & 0 deletions DockerFile
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
FROM node:14


WORKDIR /webapps/do-secure-browser-interface

COPY . /webapps/do-secure-browser-interface

RUN npm install

RUN rm -rf ~/.ssh

CMD ["npm","start"]
108 changes: 68 additions & 40 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,70 +1,98 @@
# Getting Started with Create React App
### Title
Doselect Secure Browser

This project was bootstrapped with [Create React App](https://github.com/facebook/create-react-app).
### Description
This project is a web application for Doselect secure browser interface. The application is built with React CRA, SCSS for styling, and UBA to track various click, view ,error log activites.

## Available Scripts

In the project directory, you can run:
### Use cases
Main UI interface for application.
All executable commands must be passed from there to Application.
Uba logs for both interface and application.

### `npm start`

Runs the app in the development mode.\
Open [http://localhost:3000](http://localhost:3000) to view it in your browser.
### Project Workflow.

The page will reload when you make changes.\
You may also see any lint errors in the console.

### `npm test`
1. TestaccessInput Page -> Candidate can direct input test link and access test in secure browser application .Failover case if browser does not prompt directly to Application.

Launches the test runner in the interactive watch mode.\
See the section about [running tests](https://facebook.github.io/create-react-app/docs/running-tests) for more information.
2. Instruction Page -> Can open in any normal browser .
Main cta
a. To download the Application
b. To redirect to application (Doselect secure browser) by appending all qyeryParams (imp)
QueryParams
a. dsTestUrl
b. testName
c. CandidateEmail

### `npm run build`
3. Configure page (main component) -> This page will open in Application.
Use case -> Will pass all required command to executed . ALl commands are present in utils folder
a. System notification check.
b. Check all running process by appending name of whitelisted app from utils
c. Check for number of wired/wireless displays connected.

Builds the app for production to the `build` folder.\
It correctly bundles React in production mode and optimizes the build for the best performance.
4. PreTestConfigure ->
Usecase:
a. Start some recurring command that executes after certain interval
b. Send signal to Electron application that run BLOCK NAVIGATION SCRIPT.
c. send signal to start test and redirect to ASSESSMENT-URL.

The build is minified and the filenames include the hashes.\
Your app is ready to be deployed!

See the section about [deployment](https://facebook.github.io/create-react-app/docs/deployment) for more information.

### `npm run eject`

**Note: this is a one-way operation. Once you `eject`, you can't go back!**
### Deployment
1.
2. Docker (need to configure seperate domain for each docker (central2 is configured)) :
a. Build image with DockerFile present in Project directory.
b. Move to /etc/ngnix/sites-enabled.
c. Create folder with name secure_browser
d Append content as given below:
###################### -> below content only (dont copy these special character)

If you aren't satisfied with the build tool and configuration choices, you can `eject` at any time. This command will remove the single build dependency from your project.
server {

Instead, it will copy all the configuration files and the transitive dependencies (webpack, Babel, ESLint, etc) right into your project so you have full control over them. All of the commands except `eject` will still work, but they will point to the copied scripts so you can tweak them. At this point you're on your own.
listen 80;
client_max_body_size 4G;
server_name securebrowser.central2.dev.sg1.chsh.in;

You don't have to ever use `eject`. The curated feature set is suitable for small and middle deployments, and you shouldn't feel obligated to use this feature. However we understand that this tool wouldn't be useful if you couldn't customize it when you are ready for it.
proxy_read_timeout 600s;
proxy_send_timeout 600s;
keepalive_timeout 600s;

## Learn More
location / {
proxy_redirect off;
proxy_set_header Host $host;
proxy_http_version 1.1;
real_ip_header X-Forwarded-For;
set_real_ip_from 0.0.0.0/0;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection "upgrade";
proxy_pass http://localhost:5060;
}
}

You can learn more in the [Create React App documentation](https://facebook.github.io/create-react-app/docs/getting-started).

To learn React, check out the [React documentation](https://reactjs.org/).
####################################### ends

### Code Splitting
e. Run command :
docker run --rm -d -p 5060:3000 -v "$(pwd)/src:/webapps/do-secure-browser-interface/src" -v"$(pwd)/public:/webapps/do-secure-browser-interface/public" -v "$(pwd)/.env:/webapps/do-secure-browser-interface/.env" --name secure_browser do_secure_browser


This section has moved here: [https://facebook.github.io/create-react-app/docs/code-splitting](https://facebook.github.io/create-react-app/docs/code-splitting)
3. Local : After installing all dependencies then Run : Npm run start

### Analyzing the Bundle Size

This section has moved here: [https://facebook.github.io/create-react-app/docs/analyzing-the-bundle-size](https://facebook.github.io/create-react-app/docs/analyzing-the-bundle-size)
### FAQS
1. Why we are passing command directly from here to application?
Easy to add or remove more commands. Can configure for particluar use case. No needto push updates again and again.
Can send changes with zero downtime.

### Making a Progressive Web App
2. How Application communicate with frontend ?
When any page open's in application . App embed window.electron with some function configure in do-secure-browser-backend/preload.js

This section has moved here: [https://facebook.github.io/create-react-app/docs/making-a-progressive-web-app](https://facebook.github.io/create-react-app/docs/making-a-progressive-web-app)
3. How application logs are passed to UBA
Any log must be passed to listner added and then send to uba event

### Advanced Configuration

This section has moved here: [https://facebook.github.io/create-react-app/docs/advanced-configuration](https://facebook.github.io/create-react-app/docs/advanced-configuration)

### Deployment

This section has moved here: [https://facebook.github.io/create-react-app/docs/deployment](https://facebook.github.io/create-react-app/docs/deployment)

### `npm run build` fails to minify

This section has moved here: [https://facebook.github.io/create-react-app/docs/troubleshooting#npm-run-build-fails-to-minify](https://facebook.github.io/create-react-app/docs/troubleshooting#npm-run-build-fails-to-minify)
Loading