-
Notifications
You must be signed in to change notification settings - Fork 62
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #3 from sandnon/master
Change import mode to make it more reusable
- Loading branch information
Showing
4 changed files
with
11 additions
and
12 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,14 +1,13 @@ | ||
# coding: utf-8 | ||
import lastpass | ||
|
||
import fetcher | ||
|
||
class Blob(object): | ||
def __init__(self, bytes, key_iteration_count): | ||
self.bytes = bytes | ||
self.key_iteration_count = key_iteration_count | ||
|
||
def encryption_key(self, username, password): | ||
return lastpass.Fetcher.make_key(username, password, self.key_iteration_count) | ||
return fetcher.Fetcher.make_key(username, password, self.key_iteration_count) | ||
|
||
def __eq__(self, other): | ||
return self.bytes == other.bytes and self.key_iteration_count == other.key_iteration_count |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters