Commit Graph

71 Commits (af0a630ea39ff2e803c8708bc645553413912cb3)

Author SHA1 Message Date
Jordan Wright ec8b17238e General code cleanup as part of an effort to integrate staticcheck into our CI pipeline. 2020-05-25 21:46:36 -05:00
Jordan Wright 6251ea6a02
Fixing issues - get values from non objects (#1773)
After calls to get Template, Page, and SMTP, if the objects aren't found then we're currently trying to display error message using the name values of the non objects. This changes this behavior such that we use the name values from the campaign object to give better log messages.
2020-03-05 07:31:19 -06:00
Jordan Wright 8162a80cb1
Improve the Performance of Sending Emails (#1753)
Adding the ability to cache campaigns on maillogs to greatly improve generation time (and, by extension, sending speed and memory usage).
2020-02-29 20:19:54 -06:00
Jordan Wright 3d525525ea Added campaign ID to the webhook JSON payload 2020-01-30 07:09:04 -06:00
JoseW3b 91d798336f Get send_by_date (#1720)
Get send_by_date field when query on GetCampaignSummary and GetCampaignSummaries
2020-01-15 22:02:19 -06:00
Alex Maslakov 28cd7a238e Add Webhook Support
Adds support for managing outgoing webhooks. Closes #1602
2019-12-15 20:27:21 -06:00
Jordan Wright 44f88401bb
Performance Improvements for Campaign and Group Creation (#1686)
This commit significantly improves the performance of campaign and group creation by changing database access to use transactions.

It should also make things more consistent with campaign creation. Specifically, this will ensure that the entire campaign gets created before emails start sending, while I anticipate this will fix #1643, #1080, (possibly) #1677, and #1552.
2019-12-02 23:00:11 -06:00
Jordan Wright 53b3a98521 Deleting maillogs when a campaign is completed to prevent accidental future emails from being sent. Fixes #719 2018-12-15 22:09:15 -06:00
Jordan Wright c14be36e05 Delete maillogs if a campaign is deleted. Fixes #1318 2018-12-15 21:47:40 -06:00
Jordan Wright a73ac4ab7c Fixed various minor linting issues 2018-12-15 21:38:51 -06:00
Jordan Wright 47f0049c30
Refactor servers (#1321)
* Refactoring servers to support custom workers and graceful shutdown.
* Refactoring workers to support custom mailers.
* Refactoring mailer to be an interface, with proper instances instead of a single global instance
* Cleaning up a few things. Locking maillogs for campaigns set to launch immediately to prevent a race condition.
* Cleaning up API middleware to be simpler
* Moving template parameters to separate struct
* Changed LoadConfig to return config object
* Cleaned up some error handling, removing uninitialized global error in models package
* Changed static file serving to use the unindexed package
2018-12-15 15:42:32 -06:00
Jordan Wright d6cbc1a936 Minor cleanup for campaign results 2018-10-08 10:49:21 -05:00
Jordan Wright 7dcf30f277
Add Support for Timed Campaigns (#1184)
This builds on the work from @c-f in #1090 to fully add support for "timed" campaigns, in which the emails are spaced apart as opposed to all being sent at once.
2018-09-02 11:17:52 -05:00
Jordan Wright ebb6cd61b2 Implemented the ability to preview landing pages when sending a test email. 2018-06-08 21:20:52 -05:00
Jordan Wright 420410b52c Refactored result updating to be in result.go.
Added the modified_date field to results so it's easy to keep track of the last results that were modified without having to parse every event. Updated the tests to reflect the changes.
2018-05-26 21:26:34 -05:00
Jordan Wright 5d23263898
Moved logging to logrus package. Not perfect yet (still want to update the access logs), but should set the foundation to make better logging in the future. 2018-05-03 19:07:41 -05:00
Jordan Wright f21536da7c
Adding "Report Email" Support (#1014)
Adds the capability to report phishing campaigns using an email client extension.

**Note: Gophish does not currently provide an email client extension out of the box. This is simply a mechanism to let existing email client add-ons send report status information to Gophish, and have that information reflected in the dashboard.**
2018-03-18 22:03:00 -05:00
Jordan Wright c9ff8714a0
Moved rid parameter to a separate constant. Fixes #911 2018-02-22 23:02:27 -06:00
Jordan Wright 44154f3bf0 Removing duplicates in campaigns. Fixes #855 2017-12-11 22:12:17 -06:00
Jordan Wright 76ece15b71
Email refactoring (#878)
The initial pass at refactoring the way we send emails.
2017-12-09 15:42:07 -06:00
Jordan Wright e785af5c0a Disabled turboThreshold to allow campaign timeline renders for campaigns with > 1k events. Fixes #765
Moved datatables `draw()` functions to the end of a table render, rather than on every row
2017-09-26 21:29:15 -05:00
Jordan Wright 58a57589bd Updates all datetimes to use UTC on the backend. This includes a DB migration to convert existing dates.
Fixes #316
2017-08-28 22:48:49 -05:00
Jordan Wright 75600f5812 Moved all charts from Chartist to Highcharts. Closes #680. 2017-08-05 21:12:44 -05:00
Jordan Wright 66c4be3d4f Adding support for custom headers in sending profiles (#544)
Closes #215 
Closes #128
2017-02-19 18:43:08 -06:00
Jordan Wright ea7bb04156 Changed result ID's to be 7 random alphanumeric characters. Fixes #518 2017-01-27 21:16:47 -06:00
Jordan Wright 8738ebbb35 Added campaign summary routes:
/api/campaigns/summary
/api/campaigns/:id/summary

This is part of #505
2017-01-05 21:48:54 -06:00
Jordan Wright 43cbc1d65f Fixed issue with incomplete campaign creation with large user counts. Fixes #436. Fixes #368 2016-11-18 22:01:38 -06:00
Jordan Wright b403e97eee Cleaning up some email sending bugs. Fixes #329 2016-08-02 23:18:53 -05:00
Jordan Wright 1dbf061d87 Implement the ability to complete a campaign. Fixes #290.
First implementation of new alert format.
2016-07-11 22:11:40 -05:00
Jordan Wright c5d6792bba Added /campaigns/:id/results endpoint to return campaign summary and make results page much quicker.
Fixes 282.
2016-06-07 22:31:55 -05:00
Jordan Wright 082023aae0 Adding the ability to schedule campaigns. Fixes #21 2016-06-07 21:42:09 -05:00
Jordan Wright 776e54c856 Updated GetCampaign(s) to fail gracefully if certain attributes have since been deleted. Fixes #197 2016-03-23 23:41:17 -05:00
Jordan Wright d43a888b26 Updating gorm constructs to support gorm v1.0 released yesterday. 2016-03-08 22:37:55 -06:00
Jordan Wright 625f4f8dc0 Ignoring error for no sending profile found. Fixes #189 2016-03-03 18:47:10 -06:00
William Woodson abec9adfba Return an SMTP object via GET /campaigns 2016-02-27 21:12:18 -06:00
William Woodson 80fc04924d Added handling to /util/send_test_email to use default on empty template and accept a validated SMTP object from send test email workflow on sending profiles page 2016-02-27 08:32:10 -06:00
Jordan Wright 7bf2c00356 gofmt'ing 2016-02-21 21:09:14 -06:00
William Woodson 9818410fcf Updated campaign creation and send_test_email to use settings from sending profile 2016-02-21 12:05:40 -06:00
Jordan Wright bf55c03fc9 Adding position attribute for models.Result. Fixes #163. 2016-02-17 21:25:06 -06:00
Jordan Wright 3f08c160ec Added ability to have "{{.From}}" in sending a test email. Fixes #162 2016-02-17 21:09:19 -06:00
Jordan Wright a0a8a7b8ad Merge pull request #123 from gophish/61-record-browser-post
Capture Credentials Sent via POST
2016-02-02 22:54:42 -06:00
Jordan Wright ce8a9e5456 Changed status of new targets to "Sending" instead of "Unknown". Fixes #112 2016-02-01 20:42:46 -06:00
Jordan Wright bf86356fde Validating SMTP Conf. Fixes #111 2016-02-01 18:36:59 -06:00
Jordan Wright 94e43fe557 Initial commit - adding db migration as well as the logic to add the payload 2016-01-31 19:50:41 -06:00
Jordan Wright 32aaa15da7 Added documentation for multiple endpoints. Fixes #54 2016-01-24 20:47:16 -06:00
Jordan Wright e4d6e68147 Added ability to send a test email before launching a campaign 2016-01-24 20:03:53 -06:00
Jordan Wright 1d8ac6f9f3 Added better logging for campaign retrieval 2016-01-16 23:51:01 -06:00
Jordan Wright 68b39cf6a3 Temporarily removing campaign.Errors until I can find a better way to handle it. 2015-10-22 22:32:43 -05:00
Jordan Wright 01c3da611b PhishHandler now loads landing page content. Fixes #37
Now supports autocomplete for modal typeahead. Fixes #40
Users can now specify landing pages in campaigns. Fixes #39
Implemented "Email Opened" status. Fixes #38
2015-10-22 22:29:10 -05:00
Jordan Wright b574fb2741 Implemented campaign.URL. Fixed #32
Implemented {{.From}}. Fixed #36
2015-10-22 19:54:01 -05:00