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

Ui #1

Open
wants to merge 27 commits into
base: master
Choose a base branch
from
Open

Ui #1

Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
27 commits
Select commit Hold shift + click to select a range
13620c4
Added SB-admin as dashboard template
titanlambda Sep 12, 2020
884fa88
Added header and footer
abbyutk Sep 12, 2020
355d785
Added subdomain discovery page
abbyutk Sep 12, 2020
353c7b4
Added third-party library scan page
abbyutk Sep 12, 2020
7734a27
Added port scan page
abbyutk Sep 12, 2020
2f87932
Update Oage title
theamanshakya Sep 12, 2020
c97c2f8
Modified UI pages
titanlambda Sep 12, 2020
1b5e104
Added Subdomain and domain module
abbyutk Sep 12, 2020
d19d27c
Merge branch 'FOSS_hackathon' of https://github.com/titanlambda/chitr…
abbyutk Sep 12, 2020
fde47ef
Added database file
abbyutk Sep 12, 2020
677791b
commit
theamanshakya Sep 13, 2020
d0a0a84
Added aws-enum python api
titanlambda Sep 13, 2020
8752eed
Merge branch 'ui' of https://github.com/titanlambda/chitragupta into ui
titanlambda Sep 13, 2020
833dc67
Completed subdomain part
abbyutk Sep 13, 2020
9a4bf8f
commit
theamanshakya Sep 13, 2020
8fda2cf
Merge branch 'ui' of https://github.com/titanlambda/chitragupta into ui
theamanshakya Sep 13, 2020
50275c5
commit
theamanshakya Sep 13, 2020
d071a5d
commit
theamanshakya Sep 13, 2020
ea24dcf
Added web asset counter function
abbyutk Sep 13, 2020
a0ecfe3
Added web asset counter
abbyutk Sep 13, 2020
f6e97e7
Merge branch 'ui' of https://github.com/titanlambda/chitragupta into ui
titanlambda Sep 13, 2020
cbc146a
commit
theamanshakya Sep 13, 2020
9d3cc20
commiting
theamanshakya Sep 13, 2020
8084a1a
Fixed IP lookup
abbyutk Sep 13, 2020
cbf2692
commiting
theamanshakya Sep 13, 2020
c135310
Merged
abbyutk Sep 13, 2020
4571ace
Merge branch 'ui' of https://github.com/titanlambda/chitragupta into ui
abbyutk Sep 13, 2020
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
24 changes: 24 additions & 0 deletions backend/aws-enum/app.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
import enum

import flask
from aws_enum import get_assets
import json

app = flask.Flask(__name__)
app.config["DEBUG"] = True


@app.route('/', methods=['GET'])
def home():
return "Error: Method not allowed."


@app.route('/aws_assets', methods=['GET'])
def aws_assets():
assets = get_assets()
# json_format = json.dumps(assets)
return assets


if __name__ == "__main__":
app.run(debug=True, host='0.0.0.0', port=8080)
69 changes: 69 additions & 0 deletions backend/aws-enum/aws_enum.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,69 @@
import sys
import boto3


# *******************************
# s3 - boto3 script (python)
def get_s3_details():
s3 = boto3.client('s3')
response = s3.list_buckets()
# Output the bucket names
print('Existing buckets:')
buckets = []
for bucket in response['Buckets']:
new_bucket = {"name": bucket["Name"], "created": bucket["CreationDate"]}
buckets.append(new_bucket)
return buckets


# *******************************
# ec2 - boto3 script (python)
def get_ec2_details():
ec2 = boto3.resource('ec2')
ec2_buckets = []

for instance in ec2.instances.all():
print(instance.id, instance.state)
new_ec2_bucket = {"name": instance.id, "state": instance.state}
ec2_buckets.append(new_ec2_bucket)
return ec2_buckets


# *******************************
# ec2 - boto3 script (python)
def get_rds_details():
client = boto3.client('rds')
response = client.describe_db_instances()
rds_details = []

for r in response['DBInstances']:
db_name = r['DBName']
db_instance_name = r['DBInstanceIdentifier']
db_type = r['DBInstanceClass']
db_storage = r['AllocatedStorage']
db_engine = r['Engine']
print(db_instance_name, db_type, db_storage, db_engine)
new_rds_data = {"db_name": db_name, "db_instance_name": db_instance_name,
"db_type": db_type, "db_storage": db_storage,
"db_engine": db_engine}
rds_details.append(new_rds_data)
return rds_details


def get_assets():
asset = {}
asset["s3"] = get_s3_details()
asset["ec2"] = get_ec2_details()
asset["rds"] = get_rds_details()
return asset


if __name__ == "__main__":
print("S3 Details...\n")
get_s3_details()

print("EC2 Details...\n")
get_ec2_details()

print("RDS Details...\n")
get_rds_details()
2 changes: 2 additions & 0 deletions backend/aws-enum/requirements.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
boto3
flask
13 changes: 13 additions & 0 deletions chitragupta-dashboard/.browserslistrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
# https://github.com/browserslist/browserslist#readme

>= 1%
last 1 major version
not dead
Chrome >= 60
Firefox >= 60
Edge >= 15.15063
Explorer 11
iOS >= 10
Safari >= 10
Android >= 6
not ExplorerMobile <= 11
1 change: 1 addition & 0 deletions chitragupta-dashboard/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
node_modules
14 changes: 14 additions & 0 deletions chitragupta-dashboard/.travis.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
language: node_js
git:
depth: 3
node_js:
- "node"
install: npm install
script:
- npm test
- gulp
cache:
directories:
- node_modules
notifications:
email: false
Loading