IBM QRadar SOAR

IBM QRadar SOAR

Join this online user group to communicate across Security product users and IBM experts by sharing advice and best practices with peers and staying up to date regarding product enhancements.

 View Only
  • 1.  New line in email

    Posted Fri July 05, 2024 02:31 AM

    I'm trying to send emails from SOAR with the Microsoft Exchange Online app. At first I made a form that would send emails, now I want to make some standard reply emails to send them quickly. The issue I'm facing is that it's ignoring new lines. What I have in my code:

    inputs.exo_message_body    = """Hi,\nThank you for reporting suspicious content, the email will be analyzed.\nWe'll let you know the outcome.\nKind regards,\ncyber team"""
    

    What I get:

    Hi,Thank you for reporting suspicious content, the email will be analyzed.We'll let you know the outcome.Kind regards,cyber team

    Why is SOAR ignoring new lines how to I make it work?

    PS. it's a rough translation of the response 



    ------------------------------
    Maria Czapkowska
    ------------------------------


  • 2.  RE: New line in email

    Posted Mon July 08, 2024 12:50 AM

    Hi Maria Czapkowska,

    I think you are misunderstanding how to transmit data. For mail, it is mostly transmitted as HTML body. In this case, if you want to break the line, you can try replacing "/n" with "<br>".



    ------------------------------
    Dũng Đặng
    ------------------------------



  • 3.  RE: New line in email

    Posted Mon July 08, 2024 01:17 AM

    I appreciate that you're trying to help, but you are wrong. Microsoft Exchange Online app doesn't understand html and adding a break line caused an error, I tried it before posting the question.



    ------------------------------
    Maria Czapkowska
    ------------------------------



  • 4.  RE: New line in email

    Posted Mon July 08, 2024 11:29 AM

    The Exchange Online app does send HTML.   What is the error you see when you use <br> ?

            # Create the message in the required json format
            message_json = {"message": {"subject": subject,
                                        "body": {"contentType": "HTML", "content": body},
                                        "toRecipients": recipient_list},
                            "saveToSentItems": "true"}


    ------------------------------
    AnnMarie Norcross
    ------------------------------



  • 5.  RE: New line in email

    Posted Tue July 09, 2024 01:57 AM

    The playbook crashed when trying to run it because of unknown character <br> 

    Ar you sure we're talking about the same app? Here's the one I'm using it doesn't have a field "message_json" and I don't see anything about it in the documentation. 



    ------------------------------
    Maria Czapkowska
    ------------------------------



  • 6.  RE: New line in email

    Posted Tue July 09, 2024 08:50 AM

    Hi Maria

    Yes that is the integration I am using.  The code is from the app that shows it is sending HTML format when sending the mail.  When I run the playbook Exchange Online Send Message - Example (PB).  When I enter the body text: I get email body in the screenshot...

    Hi,<br>Thank you for reporting suspicious content, the email will be analyzed.<br>We'll let you know the outcome.<br>Kind regards,<br>cyber team



    ------------------------------
    AnnMarie Norcross
    ------------------------------



  • 7.  RE: New line in email

    Posted Tue July 09, 2024 08:55 AM

    Can you post the error you are seeing from the playbook or from the app log file?



    ------------------------------
    AnnMarie Norcross
    ------------------------------