Commit Graph

9169 Commits

Author SHA1 Message Date
Mike Stone
09178a9ee8 Autofocus first field on forms (#191) 2016-09-19 14:33:43 -04:00
Mike Stone
0e08a6e698 Reset password page submit (#184)
* API client sends reset password requests

* ResetPasswordPage actions and reducer

* Reset password happy path
2016-09-19 11:35:38 -04:00
Mike Stone
482d025d05 Reset password page (#181)
* Extracts stacked boxes UI to a re-usable component

* Presence validator

* Equality validator

* Adds ResetPasswordFrom

* PasswordResetPage component and route

* Ex icon on forgot pw page goes to login

* Smooth out the fonts so they match the mocks

* Remove dynamic background and refactor colors
2016-09-16 17:19:37 -04:00
Mike Stone
cfdd665673 Fixes multiple logos on login successful page (#173) 2016-09-16 10:32:54 -07:00
Victor Vrantchan
1de9f6bd89 nicer validation errors (#180) 2016-09-16 11:23:48 -04:00
Mike Stone
5ea9115a95 Forgot password submit (#168)
* Authentication middleware

* API client refactor

* Configure API client to make forgot_password requests

* Successfully submit forgot password form

* Display server errors for unknown email address
2016-09-16 09:55:46 -04:00
Victor Vrantchan
a069ec9acf add devMode MailService to speed up testing (#178)
running with the dev flag will print the content of an email to stdout
2016-09-16 08:55:09 -04:00
Victor Vrantchan
f46a951da3 Add /me route (#177)
* i like how I wrote this to never call svc direcly

* rename func

* apparently not everywhere

* add service method for authenticated user

* oops forgot to check this in
2016-09-15 21:35:52 -07:00
Zachary Wasserman
fab4759926 Fix bug creating session with 0 timestamp (#171)
If AccessedAt is left in the zero value, MySQL will complain with the following
error: Error 1292: Incorrect datetime value: '0000-00-00' for column 'accessed_at' at row 1. Now we initialize AccessedAt when creating a new
session.
2016-09-15 15:53:47 -07:00
Victor Vrantchan
0ac63c9963 Allow with Logins with email address (#174)
The Auth service now accepts emails in the username field
The UserService now rejects user creation if the user has @ in the username.
2016-09-15 15:27:55 -04:00
Zachary Wasserman
f968ae3f8f Default to MySQL store and add --dev flag (#170)
Switches the default datastore back to MySQL, and adds a --dev flag to the
serve command that will cause the in-memory datastore to be used.

Closes #166
2016-09-15 10:20:36 -07:00
Zachary Wasserman
0702dccb7f Only attempt to parse config file if it is specified by flag (#169)
Previously, the behavior was to search for the config file in a variety of
locations. Now we only attempt to load a config file if it has been explicitly
specified with `-c` or `--config`.

Fixes #165.
2016-09-15 08:44:05 -07:00
Victor Vrantchan
df19fd4b7c Update users service (#156)
Closes #144 #145 #160 
Implements PATCH method on user and endpoint middleware for authnz
Implements `reset_password` (with token) and `forgot_password` endpoints
Added godoc comments for UserService interface
Shift to using testify/assert in test code
Multiple fixes/changes to the UserService API
2016-09-15 10:52:17 -04:00
Mike Stone
40af0d29ef Forgot password (#162)
* GradientButton components

* Style guide updates

* Display errors and override styles for InputFieldWithIcon

* Envelope Icon

* Login page form submission (#157)

* API client utility

* moves test helpers to the test directory

* Utility to namespace local storage keys

* LoginSuccessfulPage component

* Check icon

* adds auth to redux state

* successful form submission

* Allow tests to load dummy SVG static images & test fixes

* ForgotPassword Page, Form & route

* Email validator
2016-09-14 16:31:54 -04:00
Zachary Wasserman
713c248f2e Simplify test error check (#167) 2016-09-14 12:15:14 -07:00
Mike Arpaia
e8384a7655 assertifying the tests (#163) 2016-09-14 11:40:51 -07:00
Victor Vrantchan
da05e360ac print version info (#164)
add version package and print version commands
make build now sets build info like git branch and revision when creating a binary.
2016-09-14 13:19:11 -04:00
Zachary Wasserman
885db1a597 Refactoring for config patterns (#159)
This PR refactors most of the codebase to use the new config patterns implemented in #149. Now the core service keeps a copy of the KolideConfig struct, and service methods can reference the configuration in that struct when they need it. The most significant refactoring is in the sessions code, separating the business logic from the storage layer.
2016-09-14 09:11:06 -07:00
Mike Stone
b638ae186d Login page form submission (#157)
* API client utility

* moves test helpers to the test directory

* Utility to namespace local storage keys

* LoginSuccessfulPage component

* Check icon

* adds auth to redux state

* successful form submission

* Allow tests to load dummy SVG static images & test fixes
2016-09-13 22:43:26 -07:00
Zachary Wasserman
6cb05a58e6 Pattern for defining and loading application configuration (#149)
This provides a new pattern for defining and loading configuration for the Kolide server. With this PR, configuration is stored in the `config.KolideConfig` struct, and loaded through `config.Manager`. Refer to the patterns in `config/config.go` and `cli/prepare.go` to see how configuration is defined and used.

A follow-up PR will work on removing further references to `viper` throughout the codebase, instead preferring to access configuration through the strongly typed `KolideConfig`.
2016-09-12 10:26:56 -07:00
Mike Arpaia
370cc4efa8 rm .vscode 2016-09-12 09:29:30 -07:00
Jason Meller
5e9f93d08a Add assets folder so we can serve images (#155) 2016-09-12 12:11:18 -04:00
Victor Vrantchan
a27752fd2c jwtKey should be []byte but string is returned (#154) 2016-09-12 11:31:58 -04:00
Mike Stone
ac9a38c207 Login page scaffolding (#142)
* LoginPage component and route

* animated SVG background image utility

* Kolide text, User, Lock, & Kolide logo SVG icons

* styleguide

* Adds global footer

* Adds InputFieldWithIcon component

* Adds LoginForm component

* Render LoginForm from the LoginPage
2016-09-12 11:14:07 -04:00
Victor Vrantchan
82cad97c04 rename mock datastore to inmem (#150)
* rename mock datastore to inmem

* fix tests
2016-09-09 21:39:38 -04:00
Victor Vrantchan
300b7ac2db pretty-print JSON response. (#147)
NOTE: SetIndent() was introduce in 1.7
2016-09-09 08:34:53 -04:00
Victor Vrantchan
05b1afd635 Update user properties (#143)
* renamed NeedsPasswordReset field for clarity
This field was not obvious when it should be set or checked. This makes it a bit more obious.
The property should only be set if the password request was requested by an admin.
Having this property checked should
- invalidate current user auth token
- force user to reset password on their next login
- NOT send a password reset email

* add GravatarURL property
we considered uploading and storing an image url in the future as well

* Add a user property to save the user's job role/position
2016-09-08 18:57:05 -04:00
Mike Stone
a0a035f2c4 Icon component setup & bg image (#133) 2016-09-08 08:50:44 -04:00
Mike Arpaia
8bf2b7ee7b Forgot to specify that logout is post (#136) 2016-09-07 22:58:25 -04:00
Mike Arpaia
e7cabd0b73 Removing npm install --dev flag (#137) 2016-09-07 22:57:05 -04:00
Mike Arpaia
251043970b Header based JWT authentication (#131)
* add a test data subcommand

* updated sessions stuff

* merge and tests
2016-09-07 21:24:11 -04:00
Mike Stone
906bf79526 Changes CSS styles to JS using Radium (#129) 2016-09-07 16:07:45 -04:00
Victor Vrantchan
88e4be20df stdmux api routes should have a slash at the end (#132) 2016-09-07 16:02:55 -04:00
Victor Vrantchan
3ffc1028e4 move serving static assets outside of the API handler (#130) 2016-09-07 15:19:54 -04:00
Mike Arpaia
8436e3ea17 Removing unused mock package (#128) 2016-09-06 23:26:44 -04:00
Mike Stone
47e28d29aa Redux configuration (#122) 2016-09-06 20:04:02 -04:00
Mike Arpaia
ff92f6749a Osqueryd Service (#119)
* host service stuff

* working on the osquery service api

* log status and results logs
2016-09-06 17:28:07 -04:00
Mike Arpaia
bad0d62452 Remove eslint config from package.json (#126) 2016-09-06 17:22:57 -04:00
Mike Arpaia
47aa83a911 Move test setup out of root (#124) 2016-09-06 17:13:03 -04:00
Mike Arpaia
cab34eb46c Moving development docker-compose out of root (#125) 2016-09-06 17:09:25 -04:00
Mike Arpaia
7a67e98eda Making JS tests windows friendly (#123) 2016-09-06 17:00:34 -04:00
Mike Stone
a90645a95f Testing/linting setup (#120) 2016-09-06 14:41:16 -04:00
Mike Stone
1e36dabbdc Adding the watch flag to webpack (#118) 2016-09-06 11:23:33 -04:00
Mike Arpaia
9be7eacc73 generate-dev 2016-09-06 11:08:19 -04:00
Victor Vrantchan
0a3f29ade5 small fixes in endpoint error handling (#117)
* space in ,omitempty does not omit the field
https://play.golang.org/p/TF_itLk50g

* return service errors as part of the response struct
2016-09-06 11:02:11 -04:00
Mike Arpaia
b5b4796a5d rm go generate 2016-09-05 18:02:38 -04:00
Mike Arpaia
6bdf3fba4b cleaning up some development files (#115) 2016-09-05 17:58:49 -04:00
Mike Arpaia
a06f5b2afb main and readme updates (#114)
* main and readme updates

* go vet error
2016-09-05 17:40:34 -04:00
Mike Arpaia
6c26faae1a Merge pull request #103 from kolide/kittypes
Merge go-kit service implementation into master
2016-09-05 16:07:37 -04:00
Mike Arpaia
121af829d0 removing old server implementation (#109) 2016-09-05 16:03:58 -04:00