aboutsummaryrefslogtreecommitdiff
path: root/server.go
Commit message (Collapse)AuthorAgeFilesLines
* Make New return the ServerSimon Ser2020-01-081-5/+5
| | | | This will be useful to implement hot reload.
* Add a default CSPSimon Ser2019-12-181-0/+7
| | | | | Disallows loading external ressources. Providers can override it with their reverse proxy settings.
* Remove the public/ directorySimon Ser2019-12-161-1/+1
| | | | | Now that all templates are provided by plugins, there's no need to have a public/ directory. Themes can be in /themes instead of /public/themes.
* Introduce base pluginSimon Ser2019-12-161-28/+7
| | | | | | This plugin offers base IMAP/SMTP functionality. References: https://todo.sr.ht/~sircmpwn/koushin/39
* Add an API for Go pluginsSimon Ser2019-12-161-1/+7
| | | | References: https://todo.sr.ht/~sircmpwn/koushin/39
* Fix undefined ErrSessionExpiredSimon Ser2019-12-121-1/+1
| | | | Fixes: f07ab5263246 ("Add docs")
* Add docsSimon Ser2019-12-111-2/+6
|
* Export Server.{Sessions,Plugins}Simon Ser2019-12-111-9/+8
| | | | And unexport a few internal functions.
* Unexport NewSessionManagerSimon Ser2019-12-111-1/+1
| | | | This isn't intended to be used by plugins.
* Export Context.SetSession, unexport Session.TokenSimon Ser2019-12-111-5/+6
| | | | | | | I'm uneasy exposing the token to plugins, I prefer to hide it if possible to prevent mis-use. This change allows plugins to logout users.
* Export ContextSimon Ser2019-12-111-9/+14
| | | | This allows plugins to access it.
* Allow plugins to add new routesSimon Ser2019-12-101-0/+4
| | | | References: https://todo.sr.ht/~sircmpwn/koushin/6
* Reconnect to IMAP server when logged outSimon Ser2019-12-091-0/+1
| | | | | | | | | | | | | | | The session manager has been upgraded to deal with reconnections. Each session has its own expiration timer. Each time a request is received, the expiration timer is reset. A session can be closed (this is used when the user wants to logout). When the IMAP connection is closed by the server, it's set to nil in the session. The next time an IMAP command needs to be issued, the connection is re-established. Closes: https://todo.sr.ht/~sircmpwn/koushin/30
* Make SessionManager create the IMAP clientSimon Ser2019-12-091-1/+1
| | | | | This will allow SessionManager to re-connect when the IMAP server logs the user out.
* Rename ConnPool to SessionManagerSimon Ser2019-12-091-4/+4
|
* Add a Lua API to set template filtersSimon Ser2019-12-091-4/+4
|
* Add basic support for pluginsSimon Ser2019-12-091-0/+8
|
* Extract HTTP handlers in separate fileSimon Ser2019-12-041-263/+2
|
* Add basic theme supportSimon Ser2019-12-041-12/+21
| | | | References: https://todo.sr.ht/~sircmpwn/koushin/1
* Make message view's Back link set the mailbox pageSimon Ser2019-12-031-4/+5
| | | | | | | This allows to go back and forth between the mailbox view and the message view. References: https://todo.sr.ht/~sircmpwn/koushin/22
* Add basic pagination to message listSimon Ser2019-12-031-1/+22
| | | | References: https://todo.sr.ht/~sircmpwn/koushin/22
* Fix missing OutgoingMessage.InReplyTo assignmentSimon Ser2019-12-031-9/+5
|
* Add basic support for multiple recipientsSimon Ser2019-12-031-3/+2
|
* Add support for replying to a messageSimon Ser2019-12-031-5/+59
|
* Add empty CSS stylesheetSimon Ser2019-12-031-1/+1
| | | | References: https://todo.sr.ht/~sircmpwn/koushin/19
* Escape mailbox names in URLsSimon Ser2019-12-031-2/+10
| | | | Closes: https://todo.sr.ht/~sircmpwn/koushin/14
* Add session lockSimon Ser2019-12-031-12/+33
| | | | | | | HTTP requests can be processed in parallel, but we only have one IMAP connection per session. Closes: https://todo.sr.ht/~sircmpwn/koushin/12
* Pre-fill composer with sender addressSimon Ser2019-12-031-7/+13
|
* Add basic SMTP supportSimon Ser2019-12-031-2/+41
|
* Save username/password in sessionSimon Ser2019-12-031-2/+6
| | | | | This is required for authenticating with the SMTP server when composing a new message.
* Parse SMTP URL from CLISimon Ser2019-12-031-6/+47
|
* Add context to errorsSimon Ser2019-12-031-5/+5
|
* Add compose viewSimon Ser2019-12-031-0/+8
|
* Add logout routeSimon Ser2019-12-031-0/+9
|
* Set HTTP error handlerSimon Ser2019-12-031-0/+11
|
* Display & download any message partSimon Ser2019-12-031-21/+65
|
* Extract string conversion functionsSimon Ser2019-12-031-30/+0
|
* go fmtSimon Ser2019-12-031-9/+9
|
* Add basic message viewSimon Ser2019-12-021-0/+56
|
* Add basic message listSimon Ser2019-12-021-3/+9
|
* Extract IMAP functions into separate fileSimon Ser2019-12-021-37/+2
|
* List mailboxesSimon Ser2019-12-021-4/+24
|
* Add initial login logicSimon Ser2019-12-021-4/+151
|
* Add HTTP server boilerplateSimon Ser2019-12-021-0/+25