Giter VIP home page Giter VIP logo

scmn-dev / secman Goto Github PK

View Code? Open in Web Editor NEW
81.0 7.0 10.0 32.79 MB

[Archived] ๐Ÿ‘Š Human-friendly and amazing secrets manager.

Home Page: https://secman.dev

License: MIT License

Go 27.78% TypeScript 24.29% JavaScript 6.32% Batchfile 0.01% Dockerfile 0.68% PowerShell 0.16% Shell 0.15% HTML 0.29% Vue 36.30% SCSS 4.04%
password-manager secman cli typescript crypto secrets-manager human-friendly manager tui terminal-based

secman's Introduction

Archived

since 30 april 2022, secman has archived after two years of working, the reason is that there is not enough interest in this project


Secman Secman

secman is a password manager can store, retrieves, generates, and synchronizes passwords, The most important difference is secman is not GPG cored. Instead, it uses a master password to securely store your passwords. and you can easily manage your passwords from everywhere with Secman Cloud ๐Ÿ˜‰.

Projects

Project Package Version Links
CLI scmn-dev/secman version README.md
Hub @secman/hub version README.md
Scc @secman/scc version) README.md
Crypto @secman/crypto version) README.md

Featuers

  • Not GPG cored.
  • It uses a master password to securely store your passwords.
  • It syncs your passwords.
  • Easy to use.
  • It is written in Go to be fast.
  • You can easily manage your passwords from everywhere, from desktop, web, command line, and more.

to learn about secman types, check out the secman types page.

Installation โฌ‡

Secman CLI

Using script

  • Shell
curl -sL https://u.secman.dev | bash
  • PowerShell
iwr -useb https://w.secman.dev | iex

then restart your powershell

Homebrew

brew install scmn-dev/tap/secman

Scoop

scoop bucket add secman https://github.com/scmn-dev/scoop
scoop install secman

Secman Hub

Refer to secman hub instructions.

Secman Web Extension

Check out secman web extension for installation instructions.

Usage

Some Resources

Contributing

Thanks for your interest in contributing to secman. You can start a development environment with gitpod

open in gitpod

Special thanks โค

thanks to @charmbracelet for thier awesome TUI libraries ๐Ÿ—.

License

secman is licensed under the terms of MIT License

secman's People

Contributors

abdfnx avatar codacy-badger avatar david-tomson avatar dependabot[bot] avatar imrxm7md avatar kishinskiy avatar secman-bot avatar snyk-bot avatar timothee-cardoso avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar

secman's Issues

Secman V3

Todo

  • convert secman cli from typescript to go
  • move it to production
  • update all commands interfaces
  • integrate secman core with secman cli.
  • use @charmbracelet libraries
  • secman auth command
  • secman auth logout command
  • secman auth refresh command
  • secman delete command
  • secman docs command
  • secman generate command
  • secman info command
  • secman insert command
  • secman edit command
  • build secman lister TUI interface
  • add secman lister sidebar viewport
  • secman list command
  • secman read command, and build it with bubble-table
  • secman whoami command
  • upgrade secman web extension to v1.1.0
  • fix secman desktop issues
  • secman doctor command.
  • #68
  • @david-tomson create SMUI repo for secman ui command
  • build secman ui command
  • update Secman Core to v0.4.0 and add new features
  • finish from secman core cli (sc)
  • publish secman cli version v6.2.0
  • integrate secman with tran (in the next version ๐Ÿ“ฆ)
  • create new flags to secman auth login command (in the next version ๐Ÿ“ฆ)
  • add --user flag to secman whoami command (in the next version ๐Ÿ“ฆ)
  • add --tree-view flag to secman list command (in the next version ๐Ÿ“ฆ)
  • create secman encrypt command (in the next version ๐Ÿ“ฆ)
  • secman-archive/desktop#51
  • create w.secman.dev and u.secman.dev urls to install secman cli
  • scmn-dev/install#11

Can't Create new account

MacOS 12.1

Can't create new account

โฏ secman init
โœ– ๐Ÿ’ฟ ~/.secman already exists
โฏ rm -rf .secman
โฏ secman init
โœ” ๐Ÿ’ฟ Initialization complete
run secman auth to authenticate
โฏ secman auth
โœ” Enter your email: โ€ฆ [email protected]
โœ” Enter your master password: โ€ฆ ***********

Invalid email or master password. if you don't have an account, please create one using the command secman auth --create-account.
โฏ secman auth --create-account
โ€บ Error: Unexpected argument: --create-account
โ€บ See more help with --help

Cannot install in macOS using brew

Describe the bug
secman cannot be installed with HomeBrew using the command in https://secman.dev/download

brew tap scmn-dev/secman && brew install secman

To Reproduce
Simply to install in macOS using command in official docs:

brew tap scmn-dev/secman && brew install secman

Expected behavior
The command in your official installation instructions for HomeBrew should install secman in macOS. It seems to me that you ned to implement correctly secman.rb formula in scmn-dev/homebrew-tap repo and update the installation instructions to simply use:

brew install scmn-dev/tap/secman

Desktop (please complete the following information):

  • OS: macOS Big Sur v11.6
  • HomeBrew: v3.4.1

Additional context
Following official installation instructions for HomeBrew, this is the command to install it:

brew tap scmn-dev/secman && brew install secman

but the first command brew tap scmn-dev/secman fails with error:

โฏ brew tap scmn-dev/secman && brew install secman
Running `brew update --preinstall`...
==> Tapping scmn-dev/secman
Cloning into '/usr/local/Homebrew/Library/Taps/scmn-dev/homebrew-secman'...
remote: Enumerating objects: 193, done.
remote: Counting objects: 100% (193/193), done.
remote: Compressing objects: 100% (136/136), done.
remote: Total 193 (delta 44), reused 164 (delta 36), pack-reused 0
Receiving objects: 100% (193/193), 23.33 KiB | 1.06 MiB/s, done.
Resolving deltas: 100% (44/44), done.
Error: Invalid formula: /usr/local/Homebrew/Library/Taps/scmn-dev/homebrew-secman/secman.rb
No available formula with the name "secman".
In formula file: /usr/local/Homebrew/Library/Taps/scmn-dev/homebrew-secman/secman.rb
Expected to find class Secman, but found no classes.
Error: Cannot tap scmn-dev/secman: invalid syntax in tap!

since it's looking for a repo scmn-dev/homebrew-secman that's not in your repos. There is this other repo scmn-dev/homebrew-tap with a secman.rb formula that could be installed with:

brew install scmn-dev/tap/secman

as this repo's README states, but it also fails with error:

โฏ brew install scmn-dev/tap/secman
==> Tapping scmn-dev/tap
Cloning into '/usr/local/Homebrew/Library/Taps/scmn-dev/homebrew-tap'...
remote: Enumerating objects: 193, done.
remote: Counting objects: 100% (193/193), done.
remote: Compressing objects: 100% (136/136), done.
remote: Total 193 (delta 44), reused 164 (delta 36), pack-reused 0
Receiving objects: 100% (193/193), 23.33 KiB | 426.00 KiB/s, done.
Resolving deltas: 100% (44/44), done.
Error: Invalid formula: /usr/local/Homebrew/Library/Taps/scmn-dev/homebrew-tap/secman.rb
No available formula with the name "secman".
In formula file: /usr/local/Homebrew/Library/Taps/scmn-dev/homebrew-tap/secman.rb
Expected to find class Secman, but found no classes.
Error: Cannot tap scmn-dev/tap: invalid syntax in tap!

since the secman.rb file is empty.

redesign `secman`

Ok, now secman cli doesn't use api.secman.dev

and secman cli should login to secman api not github

to be honest, I don't like this cli, we have to make secman cli use our api and database

so, I created a small website to see the next secman

secman-v2.secman.dev

Secman V2

List Passwords

new secman

Authorize

$ secman auth

E-Mail: [email protected]
MasterPassword: **********

Insert

$ secman insert -t/--type login

Type: Login
Title: Expo
URL: expo.dev
Username: SecmanX
Password: ********
Extra:

Read

$ secman read Expo

Title: Expo
URL: expo.dev
Username: SecmanX
Password: ********
Extra:

# show password

$ secman read Expo --show-password

Title: Expo
URL: expo.io
Username: SecmanX
Password: secman_expo_31137
Extra:

Edit

$ secman edit Expo

What Do You Want To Change ?

1. Title
> 2. URL
3. Username
4. Password
5. Extra

Enter The New URL: expo.dev

# choose

$ secman edit Expo -e/--extra

Enter The New Extra: expo is a powerfull tool

Generate

$ secman generate
thlnchhmzdwzura

# with options

$ secman generate -l 10 -n -s -c
~-zEQpYXaK

# -l: Length of the generated password
# -n: Include numbers
# -s: Include symbols
# -c: Include capital-letters

# full

$ secman generate --length 16 --numbers --symbols --capital-letters
+Bu-L^uv-/*gQmN

Commands

  • auth
  • insert | new
  • read | show
  • edit
  • generate | gen
  • delete | remove | rm
  • upgrade | upg
  • uninstall | un
  • version

Maybe Added

  • change-master-password | cms
  • find | search

I know this maybe hard, but if we did it, we will be better

Tasks:

  • build beautiful help design
  • create auth command
  • add read command
  • build generate command
  • add insert cmd
  • build the lister
  • create edit command
  • create & build secman cli API
  • build secman configure.
  • make the spinner.
  • settings cmd.
  • finish from the email sender.
  • remove cmd.
  • #102
  • create init command.
  • design email.
  • #110
  • update secman.dev docs
  • build crypto command.
  • whoami cmd.
  • build v1 dir.
  • logout cmd.
  • info command.
  • init cmd.
  • update command.
  • docs command.
  • #106

There's an Error when insert or edit or remove a password

when I insert or edit or remove a password, it's shows this message

bash: ~/sm/sync.sh: Permission denied

and in install.sh we've chmod command

...
sudo chmod 755 ~/sm
...

I think the command should be like this

sudo chmod 755 ~/sm/sync.sh

use `bcrypt` as master password hasher

Storing cryptographic hashes of passwords is standard security practice, but it is equally important to select the right hashing scheme. If an attacker obtains the hashed passwords of an application, the password hashing scheme should still prevent the attacker from easily obtaining the original cleartext passwords.

so we have to use bcrypt algorithm as hasher

const crypto = require("crypto");
function hashPassword(password) {
    var hasher = crypto.createHash('md5');
    var hashed = hasher.update(password).digest("hex"); // BAD
    return hashed;
}

to

const bcrypt = require("bcrypt");
function hashPassword(password, salt) {
  var hashed = bcrypt.hashSync(password, salt); // GOOD
  return hashed;
}

Bug in ubuntu/debian package file (`.deb`)

when install .deb file, it's always appears this message

with sudo apt install ./secman_v5.3.62_amd64.deb

Reading package lists... Done
Building dependency tree
Reading state information... Done
Note, selecting 'secman' instead of './secman_v5.3.62_amd64.deb'
The following packages will be upgraded:
  secman
1 upgraded, 0 newly installed, 0 to remove and 125 not upgraded.
Need to get 0 B/10.7 MB of archives.
After this operation, 24.1 MB of additional disk space will be used.
Get:1 ~/secman-workflow/secman_v5.3.62_amd64.deb secman amd64 5.3.62 [10.7 MB]
(Reading database ... 106010 files and directories currently installed.)
Preparing to unpack .../secman_v5.3.62_amd64.deb ...
Unpacking secman (5.3.62) over (5.2.1) ...
dpkg: error processing archive ~/secman-workflow/secman_v5.3.62_amd64.deb (--unpack):
 trying to overwrite directory '/usr/share/man/man1' in package login 1:4.8.1-1ubuntu5.20.04 with nondirectory
Errors were encountered while processing:
 ~/secman-workflow/secman_v5.3.62_amd64.deb
E: Sub-process /usr/bin/dpkg returned an error code (1)

with sudo dpkg -i ./secman_v5.3.62_amd64.deb

(Reading database ... 106010 files and directories currently installed.)
Preparing to unpack secman_v5.3.62_amd64.deb ...
Unpacking secman (5.3.62) over (5.2.1) ...
dpkg: error processing archive secman_v5.3.62_amd64.deb (--install):
 trying to overwrite directory '/usr/share/man/man1' in package login 1:4.8.1-1ubuntu5.20.04 with nondirectory
Processing triggers for man-db (2.9.1-1) ...
Errors were encountered while processing:
 secman_v5.3.62_amd64.deb

the common error is trying to overwrite directory '/usr/share/man/man1' in package login 1:4.8.1-1ubuntu5.20.04 with nondirectory

I don't know what is this

Create login command

login command is like this

secman login

# now it's ask
# do you want to login by gh cli or git
โฏ gh cli
โฏ git

let's do this bro, it's a great addition for secman

When the user is not registered this message appears

open        Open Your Private Repo (non-200 OK status code: 401 Unauthorized body: "{\"message\":\"This endpoint requires you to be authenticated.\",\"documentation_url\":\"https://docs.github.com/graphql/guides/forming-calls-with-graphql#authenticating-with-graphql\"}"/.secman).

it's should be

open        Open Your Private Repo (:username/.secman).

The CheckList


  • improve secman blog.

  • publish the new release v5.3.8.

  • update gh-api.

  • build v1.0.3 version of secman desktop.

  • update changelog.

  • add two docs pages at docker.secman.dev .

  • build & publish secman desktop.

  • publish auth.secman.dev

  • add new docs.

  • create support page.

  • finish from dsk.secman.dev website.

  • upgrade secman website.

  • build extension page

  • add SME firefox extension

`Homedir` bug in windows

when I run secman init in windows

node:internal/process/promises:227
          triggerUncaughtException(err, true /* fromPromise */);
          ^

[Error: ENOENT: no such file or directory, open 'C:\undefined\.secman\settings.json'] {
  errno: -4058,
  code: 'ENOENT',
  syscall: 'open',
  path: 'C:\\undefined\\.secman\\settings.json'
}

we have to change /constants/index.ts in DOT_SECMAN_PATH

export const HOMEDIR: any =
  process.platform === "win32" ? "USERPROFILE" : "HOME";

export const DOT_SECMAN_PATH = `${HOMEDIR}/.secman`;

like this

Version Checker

when I finish from inserting a new password, update checker it's takes a long time, I think it a bug

Fetching in windows

when I fetching my new password in windows, it's always asking my github username and my password

secman fetch

[================>   ] ๐Ÿ”— Fetching... Username for 'https://github.com':
[========>           ] ๐Ÿ”— Fetching... om':

so I think we have to change fetch method of windows

from

$lastDir = pwd
cd $HOME/.secman
git pull
cd $lastDir

to

Remove-Item $HOME/.secman -Recurse -Force
secman repo clone $username/.secman

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.