-
Notifications
You must be signed in to change notification settings - Fork 777
Update and rename info.py to Bot.py #62
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 | ||||
|---|---|---|---|---|---|---|
|
|
@@ -13,20 +13,20 @@ def is_enabled(value, default): | |||||
| #--------------------------------------------------------------- | ||||||
| #--------------------------------------------------------------- , | ||||||
| SESSION = environ.get('SESSION', 'Media_search') | ||||||
| API_ID = int(environ.get('API_ID', '21484')) | ||||||
| API_HASH = environ.get('API_HASH', 'db6286a041adf07ef4244e') | ||||||
| BOT_TOKEN = environ.get('BOT_TOKEN', '7807I9ygow9sLqNQuI7hsWPm5FLNfBr9c') | ||||||
| API_ID = int(environ.get('API_ID', '32130352')) | ||||||
| API_HASH = environ.get('API_HASH', 'fddbf986bb12dee0c05b32594188d75e') | ||||||
| BOT_TOKEN = environ.get('BOT_TOKEN', '8293394314:AAGNYE5w99XbCfV9zZRlhSBIVsLRIgWZr-A') | ||||||
| #--------------------------------------------------------------- | ||||||
| #--------------------------------------------------------------- | ||||||
| ADMINS = [int(admin) if id_pattern.search(admin) else admin for admin in environ.get('ADMINS', '5016109398').split()] | ||||||
| USERNAME = environ.get('USERNAME', "https://t.me/Innocent_babe_dead") # ADMIN USERNAME | ||||||
| LOG_CHANNEL = int(environ.get('LOG_CHANNEL', '-1002190681742')) | ||||||
| MOVIE_GROUP_LINK = environ.get('MOVIE_GROUP_LINK', 'https://t.me/+K2kgCBgaat80YWQ9') | ||||||
| CHANNELS = [int(ch) if id_pattern.search(ch) else ch for ch in environ.get('CHANNELS', '-1002190681742').split()] | ||||||
| ADMINS = [int(admin) if id_pattern.search(admin) else admin for admin in environ.get('ADMINS', '8553992570').split()] | ||||||
| USERNAME = environ.get('USERNAME', "https://t.me/manuthakur01") # ADMIN USERNAME | ||||||
| LOG_CHANNEL = int(environ.get('LOG_CHANNEL', '-1003885974344')) | ||||||
| MOVIE_GROUP_LINK = environ.get('MOVIE_GROUP_LINK', 'https://https://t.me/funchannel013') | ||||||
|
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. Fix malformed default URL for movie group link. Line 24 default value has a double scheme ( 🔧 Proposed fix-MOVIE_GROUP_LINK = environ.get('MOVIE_GROUP_LINK', 'https://https://t.me/funchannel013')
+MOVIE_GROUP_LINK = environ.get('MOVIE_GROUP_LINK', 'https://t.me/funchannel013')📝 Committable suggestion
Suggested change
🤖 Prompt for AI Agents |
||||||
| CHANNELS = [int(ch) if id_pattern.search(ch) else ch for ch in environ.get('CHANNELS', '-1003828167659').split()] | ||||||
| #--------------------------------------------------------------- | ||||||
| #--------------------------------------------------------------- | ||||||
| DATABASE_URI = environ.get('DATABASE_URI', "mongodb+srv:learningbajority&appName=learningbots") | ||||||
| DATABASE_NAME = environ.get('DATABASE_NAME', "learningbots") | ||||||
| DATABASE_URI = environ.get('DATABASE_URI', "mongodb+srv://manuthakur:[email protected]/?appName=manuthakur") | ||||||
| DATABASE_NAME = environ.get('DATABASE_NAME', "manuthakur") | ||||||
| COLLECTION_NAME = environ.get('COLLECTION_NAME', 'Telegram_files') | ||||||
| #--------------------------------------------------------------- | ||||||
| #--------------------------------------------------------------- | ||||||
|
|
||||||
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.
Remove committed secrets and require env vars at startup.
Line 16, Line 17, Line 18, Line 28, and Line 29 currently include hardcoded credentials/tokens (including DB credentials in URI). This is a critical secret-leak risk.
🔐 Proposed fix (fail-fast required envs, no secret defaults)
Also applies to: 28-29
🧰 Tools
🪛 Gitleaks (8.30.0)
[high] 17-17: Detected a Generic API Key, potentially exposing access to various services and sensitive operations.
(generic-api-key)
🤖 Prompt for AI Agents