-
Notifications
You must be signed in to change notification settings - Fork 1
Feature bl 1 06012026 #9
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
base: main
Are you sure you want to change the base?
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,19 @@ | ||
| from flask import Flask, request, jsonify | ||
| from converter_service import ConversionService | ||
|
|
||
| app = Flask(__name__) | ||
| conversion_service = ConversionService() | ||
|
|
||
|
|
||
| @app.route('/api/convert', methods=['POST']) | ||
| def convert_document(): | ||
| data = request.get_json() | ||
| filename = data.get('filename') | ||
| output_format = data.get('format', 'pdf') | ||
|
|
||
| result = conversion_service.convert(filename, output_format) | ||
| return jsonify(result) | ||
|
|
||
|
|
||
| if __name__ == '__main__': | ||
| app.run(debug=True) | ||
| Original file line number | Diff line number | Diff line change | ||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|
| @@ -0,0 +1,33 @@ | ||||||||||||
| """Application configuration settings.""" | ||||||||||||
|
|
||||||||||||
| import os | ||||||||||||
|
|
||||||||||||
| # Database | ||||||||||||
| DATABASE_HOST = os.getenv("DB_HOST", "db.internal.example.com") | ||||||||||||
| DATABASE_PORT = 5432 | ||||||||||||
| DATABASE_NAME = "app_production" | ||||||||||||
| DATABASE_USER = "app_service" | ||||||||||||
| DATABASE_PASSWORD = "Pr0d_Db!S3cureP@ss2025" | ||||||||||||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. ❗Cycode: Secret of type: 'Generic Password' was found. DescriptionA generic secret or password is an authentication token used to access a computer or application and is assigned to a password variable. Cycode Remediation Guideline❗ How to revoke
Tell us how you wish to proceed using one of the following commands:
|
||||||||||||
|
|
||||||||||||
| # GitHub integration | ||||||||||||
| GITHUB_PAT = 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 | ||||||||||||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. ❗Cycode: Secret of type: 'Github Fine Grained Token' was found. DescriptionGitHub is a web-based platform for hosting and collaborating on software projects. Fine-grained personal access tokens (PATs) are a new type of personal access token introduced by GitHub that offer enhanced security to developers and organization owners. Cycode Remediation Guideline❗ How to revoke
Tell us how you wish to proceed using one of the following commands:
|
||||||||||||
| GITHUB_ORG = "acme-corp" | ||||||||||||
| GITHUB_WEBHOOK_SECRET = "whsec_k7Gm2pLqX9vNdR4tYbA1cEfHjW8uZoSi" | ||||||||||||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. ❗Cycode: Secret of type: 'Stripe Webhook Secret' was found. DescriptionA Stripe webhook is a way for Stripe to send real-time updates to your application about events that happen on your Stripe account. To use webhooks, a webhook secret is required Cycode Remediation Guideline❗ How to revoke
Tell us how you wish to proceed using one of the following commands:
|
||||||||||||
|
|
||||||||||||
| # AWS credentials | ||||||||||||
| AWS_ACCESS_KEY_ID = "AKIAUVIGFTH6XXIAP3NB" | ||||||||||||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. ❗Cycode: Secret of type: 'Aws Access Key Id' was found. DescriptionAn AWS (Amazon Web Services) access key ID is a unique identifier that is used to authenticate and authorize access to the AWS Management Console and the various AWS services and resources. An AWS access key ID consists of two parts: an access key ID and a secret access key. Cycode Remediation Guideline❗ How to revoke
Tell us how you wish to proceed using one of the following commands:
|
||||||||||||
| AWS_SECRET_ACCESS_KEY = "to21HQaNhBqBajpAnAodU8P8lthdaPJOgdy+y1w6" | ||||||||||||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. ❗Cycode: Secret of type: 'Aws Secret Access Key' was found. DescriptionAlongside with with an AWS access key , the AWS secret access key is a string of characters that is used in to sign and authenticate requests to AWS service Cycode Remediation Guideline❗ How to revoke
Tell us how you wish to proceed using one of the following commands:
|
||||||||||||
| AWS_REGION = "us-east-2" | ||||||||||||
|
|
||||||||||||
| # Slack notifications | ||||||||||||
| SLACK_BOT_TOKEN = "xoxb-8294716350192-6738201459283-qN7vXpLm2KdRtYwBs5jH1gFe" | ||||||||||||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. ❗Cycode: Secret of type: 'Slack Token' was found. DescriptionIn the scope of the Slack API, a token is an identifier that is used to authenticate Slack app app when making API requests Cycode Remediation Guideline❗ How to revoke
Tell us how you wish to proceed using one of the following commands:
|
||||||||||||
| SLACK_WEBHOOK_URL = "https://hooks.slack.com/services/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" | ||||||||||||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. ❗Cycode: Secret of type: 'Slack Webhook' was found. DescriptionA Slack webhook is a way to send a message to a Slack channel or conversation using the Slack API. Webhooks allow you to send data to a Slack channel or conversation using a simple HTTP request, without the need for a user to be present in the channel or to have a Slack bot or app installed. Cycode Remediation Guideline❗ How to revoke
Tell us how you wish to proceed using one of the following commands:
|
||||||||||||
|
|
||||||||||||
| # Stripe payments | ||||||||||||
| STRIPE_SECRET_KEY = "sk_live_51NqR7kGv2Hx8LmTpYbWdJfKs4XcZeA9uOiPn3VrBtMwCyDgEhFj" | ||||||||||||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. ❗Cycode: Secret of type: 'Stripe Api Key' was found. DescriptionStripe is a payment processing platform that allows businesses to accept payments online. To use the Stripe API, an API key is required Cycode Remediation Guideline❗ How to revoke
Tell us how you wish to proceed using one of the following commands:
|
||||||||||||
| STRIPE_PUBLISHABLE_KEY = "pk_test_placeholder" | ||||||||||||
|
|
||||||||||||
| # JWT signing | ||||||||||||
| JWT_SECRET_KEY = "xK9#mP2$vL5nQ8wR1tY4bJ7gF0hD3cA6e" | ||||||||||||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. ❗Cycode: Secret of type: 'Generic Password' was found. DescriptionA generic secret or password is an authentication token used to access a computer or application and is assigned to a password variable. Cycode Remediation Guideline❗ How to revoke
Tell us how you wish to proceed using one of the following commands:
|
||||||||||||
| JWT_ALGORITHM = "HS256" | ||||||||||||
| JWT_EXPIRATION_HOURS = 24 | ||||||||||||
| Original file line number | Diff line number | Diff line change | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| @@ -0,0 +1,10 @@ | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| # Python dependencies with known vulnerabilities (SCA triggers) | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| # Critical vulnerabilities | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| flask==1.0.2 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. ❗Cycode: Security vulnerabilities found in newly introduced dependency.
The following vulnerabilities were introduced:
Highest fixed version: 2.2.5 DescriptionDetects when new vulnerabilities affect your dependencies. Tell us how you wish to proceed using one of the following commands:
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| django==2.2.0 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. ❗Cycode: Security vulnerabilities found in newly introduced dependency.
The following vulnerabilities were introduced: Highest fixed version: 4.2.26 DescriptionDetects when new vulnerabilities affect your dependencies. Tell us how you wish to proceed using one of the following commands:
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| requests==2.19.1 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. ❗Cycode: Security vulnerabilities found in newly introduced dependency.
The following vulnerabilities were introduced:
Highest fixed version: 2.33.0 DescriptionDetects when new vulnerabilities affect your dependencies. Tell us how you wish to proceed using one of the following commands:
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| urllib3==1.24.1 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. ❗Cycode: Security vulnerabilities found in newly introduced dependency.
The following vulnerabilities were introduced:
Highest fixed version: 2.7.0 DescriptionDetects when new vulnerabilities affect your dependencies. Tell us how you wish to proceed using one of the following commands:
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| pyyaml==5.1 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. ❗Cycode: Security vulnerabilities found in newly introduced dependency.
The following vulnerabilities were introduced:
Highest fixed version: 5.4 DescriptionDetects when new vulnerabilities affect your dependencies. Tell us how you wish to proceed using one of the following commands:
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| jinja2==2.10 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. ❗Cycode: Security vulnerabilities found in newly introduced dependency.
The following vulnerabilities were introduced:
Highest fixed version: 3.1.6 DescriptionDetects when new vulnerabilities affect your dependencies. Tell us how you wish to proceed using one of the following commands:
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
❗Cycode: SAST violation: 'Usage of Flask debug mode'.
Severity: Medium
Description
Enabling Flask's debug mode exposes sensitive internal information through detailed error messages, stack traces, and the interactive Werkzeug debugger. This can allow attackers to discover application internals, leak environment variables, or even execute arbitrary code.
Cycode Remediation Guideline
✅ Do
debugmode is disabled in all production deployments of Flask applications.debug=False:❌ Don't
Truein code that is deployed.📋 References
🎥 Learning materials (by Secure Code Warrior)
Tell us how you wish to proceed using one of the following commands: