mirror of
https://github.com/SuiteCRM/SuiteCRM.git
synced 2026-03-02 19:16:58 -05:00
outgoing smtp password api key fails to save/work #5313
Labels
No labels
Area: API
Area: Campaigns
Area: Cases
Area: Clean Up
Area: Clean Up: Performance
Area: Dashlets
Area: Databases
Area: Developer Tools
Area: Elasticsearch
Area: Elasticsearch
Area: Emails
Area: Emails:Campaigns
Area: Emails:Cases
Area: Emails:Compose
Area: Emails:Config
Area: Emails:Templates
Area: Environment
Area: Installation
Area: Language
Area: Mobile
Area: Module
Area: PDFs
Area: PHP8
Area: Reports
Area: Studio
Area: Styling
Area: Upgrading
Area: Workflow
Area:Activity Stream
Area:Calls
Area:Import
Area:Projects
Area:Search
Area:Surveys
Area:Themes
Area:Users
Branch:Hotfix
Good First Issue
Hacktoberfest
Help Wanted
PR:Community Contribution
PR:Type:Enhancement
Priority:Critical
Priority:Important
Priority:Moderate
Severity: Major
Severity: Minor
Severity: Moderate
Status: Requires Code Review
Status: Requires Updates
Status: Stale
Status: Team Investigating
Status:Assessed
Status:Fix Proposed
Status:Needs Assessed
Status:Requires Automated Tests
Type: Bug
Type:Deprecated
Type:Discussion
Type:Duplicate
Type:Invalid
Type:Question
Type:Suggestion
Type:Suggestion
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
starred/SuiteCRM-SuiteCRM#5313
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @IAmBecomeDeth on GitHub (Mar 24, 2025).
Issue
This is a bug going back to 7.x version.
bug1:
you have mail_smtppass set to varchar100.
brevo (sendinblue) smtp password uses an api key. Many other services do as well.
I measured length and the password/api key I have been assigned which is 90 characters.
when saving, the password was truncated at 100 because of encryption.
I increased mail_smtppass to varchar300 using mysqladmin
the password saved 128chars
same bug/bug2:
however... it still does not work.
In addition to being really long, the password also contains two -s and there is an open bug report for special characters in passwords being saved wrong. this may be related. I can try changing to my web server email server but I don't plan to do large batches with that server so this is not a full fix
How do I manually encrypt the password and save it to this field for testing and to get by until this bug is fixed?
Possible Fix
Fix 1, increase mail_smtppass from varchar90 to varchar200.
Fix 2a bug with larger length data being decrypted and sent properly (maybe, but probably not)
fix 2b bug with escaping of special characters while saving or during use.
Steps to Reproduce the Issue
Context
anyone with an excessively long smtp password (api keys) can not send emails.
anyone with special characters in smtp password (also api keys) can not send emails.
unfortunately, as end users we have no control over api key password complexity or lengths.
Version
8.8
What browser are you currently using?
Safari
Browser Version
Safari 18.3.1
Environment Information
mysql php 8.3
Operating System and Version
ubuntu 20.04.06
@johnM2401 commented on GitHub (Mar 25, 2025):
Hey!
Thank you for raising these issues.
Just to let you know, I've transferred this over to the SuiteCRM7 repo as the SMTP password issues are present in both SuiteCRM7 and SuiteCRM8 (and stem from SuiteCRM7-side functionality.)
So, any fixes done to these in the SuiteCRM7 codebase will be pulled into SuiteCRM8.
Also, tagging as a duplicate of:
https://github.com/salesagility/SuiteCRM/issues/10506
Thank you again!
@IAmBecomeDeth commented on GitHub (Mar 25, 2025):
I was looking through the codebase to try to find the problematic code, but the code goes back and forth through several include files for different functions and I didn't have enough time yesterday. I will try to look a little deeper to find where the problem is if I can find it.