<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: DigitalOnUs</title>
    <description>The latest articles on DEV Community by DigitalOnUs (@digitalonus).</description>
    <link>https://dev.to/digitalonus</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Forganization%2Fprofile_image%2F465%2Ff8728900-6d38-4565-90eb-7b41e8d7e6fb.png</url>
      <title>DEV Community: DigitalOnUs</title>
      <link>https://dev.to/digitalonus</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/digitalonus"/>
    <language>en</language>
    <item>
      <title>How to install Boundary on Ubuntu in 3 CLI commands</title>
      <dc:creator>🦄N B🛡</dc:creator>
      <pubDate>Fri, 20 Nov 2020 00:35:53 +0000</pubDate>
      <link>https://dev.to/digitalonus/how-to-install-boundary-on-ubuntu-4c52</link>
      <guid>https://dev.to/digitalonus/how-to-install-boundary-on-ubuntu-4c52</guid>
      <description>&lt;p&gt;Press ctrl+alt+t to open a Terminal Emulator window in &lt;a href="https://www.wikihow.com/Install-Ubuntu-Linux"&gt;Ubuntu&lt;/a&gt;. &lt;/p&gt;

&lt;p&gt;Then you can copy or type this in to install Boundary on Ubuntu Linux in a terminal:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;curl -fsSL https://apt.releases.hashicorp.com/gpg | sudo apt-key add -
sudo apt-add-repository "deb [arch=amd64] https://apt.releases.hashicorp.com $(lsb_release -cs) main"
sudo apt-get update &amp;amp;&amp;amp; sudo apt-get install boundary
boundary -h
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;To install, that is all. &lt;/p&gt;

&lt;p&gt;But here's an example of running it, so you can see what your output should look like:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt; * keychain 2.8.5 ~ http://www.funtoo.org
 * Waiting 5 seconds for lock...
 * Found existing ssh-agent: 4199
 * Known ssh key: /home/nb/.ssh/id_rsa

~$ curl -fsSL https://apt.releases.hashicorp.com/gpg | sudo apt-key add -
[sudo] password for norbert: 
OK
~$ sudo apt-add-repository "deb [arch=amd64] 
https://apt.releases.hashicorp.com $(lsb_release -cs) main"
Hit:1 
http://security.ubuntu.com/ubuntu focal-security/universe amd64 DEP-11 Metadata [56.6 kB]                                                                                                                  
Get:45 http://security.ubuntu.com/ubuntu focal-security/universe amd64 c-n-f Metadata [9,364 B]                                                                                                                   
Fetched 5,693 kB in 7s (792 kB/s)                                                                                                                                                                                 
Reading package lists... Done
~$ sudo apt-get update &amp;amp;&amp;amp; sudo apt-get install boundary                                                                                                                       
Hit:4 https://apt.releases.hashicorp.com focal InRelease                                                                                                                            
Hit:5 http://us.archive.ubuntu.com/ubuntu focal InRelease                                               
Hit:6 http://security.ubuntu.com/ubuntu focal-security InRelease
Hit:7 http://us.archive.ubuntu.com/ubuntu focal-updates InRelease
Reading package lists... Done
Reading package lists... Done
Building dependency tree       
Reading state information... Done
The following NEW packages will be installed:
  boundary
0 upgraded, 1 newly installed, 0 to remove and 45 not upgraded.
Need to get 21.2 MB of archives.
After this operation, 48.9 MB of additional disk space will be used.
Get:1 https://apt.releases.hashicorp.com focal/main amd64 boundary amd64 0.1.2 [21.2 MB]
Fetched 21.2 MB in 4s (5,534 kB/s)   
Selecting previously unselected package boundary.
(Reading database ... 280569 files and directories currently installed.)
Preparing to unpack .../boundary_0.1.2_amd64.deb ...
Unpacking boundary (0.1.2) ...
Setting up boundary (0.1.2) ...
~$ echo $PATH | grep boundary
~1$ boundary -h
Usage: boundary &amp;lt;command&amp;gt; [args]

Commands:
    accounts           Manage Boundary accounts
    auth-methods       Manage Boundary auth methods
    auth-tokens        Manage Boundary auth tokens
    authenticate       Authenticate the Boundary command-line client
    config             Manage resources related to Boundary's local configuration
    connect            Connect to a target through a Boundary worker
    database           Manage Boundary's database
    dev                Start a Boundary dev environment
    groups             Manage Boundary groups
    host-catalogs      Manage Boundary host catalogs
    host-sets          Manage Boundary host sets
    hosts              Manage Boundary hosts
    roles              Manage Boundary roles
    scopes             Manage Boundary scopes
    server             Start a Boundary server
    sessions           Manage Boundary sessions
    targets            Manage Boundary targets
    users              Manage Boundary users
~$ 
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



</description>
      <category>boundary</category>
      <category>identity</category>
      <category>authentication</category>
    </item>
    <item>
      <title>Terraform Semantic Versioning as a Communication Tool</title>
      <dc:creator>🦄N B🛡</dc:creator>
      <pubDate>Thu, 19 Nov 2020 23:54:49 +0000</pubDate>
      <link>https://dev.to/digitalonus/terraform-semantic-versioning-as-a-communication-tool-3o40</link>
      <guid>https://dev.to/digitalonus/terraform-semantic-versioning-as-a-communication-tool-3o40</guid>
      <description>&lt;h1&gt;
  
  
  Communication from Shared Services
&lt;/h1&gt;

&lt;p&gt;Although moving to a Cloud Operating model and self-service means a far greater degree of ownership of infrastructure by internal customers, these still need to rely on teams of specialists to maintain the platforms, libraries, modules, etc. that those consumers of internal services, well, consume. &lt;/p&gt;

&lt;p&gt;One of the best ways for these specialists to communicate ideas to the wider org, beyond the usual meetings, workshops, and presentations, is code, specifically, versioning of code.&lt;/p&gt;

&lt;p&gt;In Terraform Enterprise, this communication can take the form of versioning re-usable modules in an internal module registry.&lt;/p&gt;

&lt;p&gt;External re-usable modules, like &lt;a href="https://registry.terraform.io/modules/hashicorp/vault/aws/latest"&gt;the Vault module&lt;/a&gt;, should have strict version pinning, and internal modules, to facilitate faster feedback loops and better communication with SRE, should have looser version pinning. &lt;/p&gt;

&lt;p&gt;Here's an example policy that you can set: &lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;Hi everyone at Rupture AgCorp IT,&lt;br&gt;&lt;br&gt;
We would like you all to make sure that you're pinning external Terraform Modules to their Minor version numbers, in accordance with Semantic Versioning (&lt;a href="https://semver.org"&gt;https://semver.org&lt;/a&gt;)&lt;br&gt;
But for internal modules, because changes to these are much more directly relevant to compliance and business changes, we now require you to have looser version pinning, to major versions only. &lt;br&gt;
This may cause issues, but they're issues we want to find out about, and handle, sooner rather than later. &lt;br&gt;
It's part of the way that we can make sure that our efforts to improve our internal services are meeting your needs, and an even better feedback mechanism than the conversations you are all so gracious to have with us on a regular basis. &lt;br&gt;
If you have any questions about this policy, or you think it's bunk, we're happy to discuss it as part of our portion of the Rupture AgCorp IT all-hands on Friday, or in person if you happen to drop by our desks. &lt;/p&gt;
&lt;/blockquote&gt;

&lt;h1&gt;
  
  
  &lt;strong&gt;But make sure everyone in the SRE group knows how to properly do Semantic Versioning, to avoid unwanted changes!&lt;/strong&gt;
&lt;/h1&gt;

&lt;p&gt;You need to do this because if someone in your core services team marks a change as a bug fix or a security patch that they should have marked as a minor or major version change, this will betray the expectations you've set with the consumers of your service. And people will give up, and all but the adventurous will just avoid adopting new versions at all. &lt;/p&gt;

&lt;p&gt;For modules maintained within your organization, a version range strategy may be appropriate if a semantic versioning methodology is used consistently or if there is a well-defined release process that avoids unwanted updates.&lt;br&gt;
--&lt;a href="https://www.terraform.io/docs/configuration/modules.html#module-versions"&gt;https://www.terraform.io/docs/configuration/modules.html#module-versions&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Here are two example use cases: &lt;/p&gt;

&lt;h3&gt;
  
  
  Use Case 1: Legacy Terraform Versions
&lt;/h3&gt;

&lt;p&gt;If you want to support Legacy Terraform versions, you can make a major version change reflect the new version of Terraform, e.g. Terraform 0.13.x would be supported by version 3.x.x of your module, and Terraform 0.12.x would be supported by version 2.x.x.&lt;/p&gt;

&lt;h3&gt;
  
  
  Use Case 2: Modules that "Wrap" External Modules
&lt;/h3&gt;

&lt;p&gt;For instance, if you have a Module that adds some company specific context or standard resources to another module, like the AKS module, and you keep making updates each month, you do not want your internal projects and Terraform code for your SaaS or IaaS footprint to have versions pinned to the patch version. If the Terraform modules for your internal systems have their dependencies from the HashiCorp registry, like &lt;a href="https://registry.terraform.io/modules/hashicorp/vault/aws/latest"&gt;HashiCorp's Vault module&lt;/a&gt;, pinned to the security patch version, or minor version, well, OK. Maybe it's needed. &lt;/p&gt;

&lt;p&gt;But if they're pinning your internally developed modules in your internal module registry to the patch version, it means you're missing out on a great chance to have productive conversations with the people who would consume your code about what they need and what they don't want. &lt;/p&gt;

&lt;p&gt;It means that if you make an important change or necessary improvement in something they're not an expert in, they'll never know! &lt;/p&gt;

&lt;p&gt;By the way, I haven't written this out of some kind of academic consideration for potential future issues. &lt;/p&gt;

&lt;p&gt;This is a real solution to a real problem that organizations even more sophisticated than my own have run into. And I recommend that if you use Terraform and have shared services, you give it serious consideration. &lt;/p&gt;

&lt;h3&gt;
  
  
  Further Reading:
&lt;/h3&gt;

&lt;p&gt;&lt;a href="https://semver.org/"&gt;https://semver.org/&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="https://dev.to/search?q=semantic%20versioning"&gt;https://dev.to/search?q=semantic%20versioning&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="https://dev.to/djmoch/regarding-semantic-versioning-hhk"&gt;https://dev.to/djmoch/regarding-semantic-versioning-hhk&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="https://dev.to/aheil/semantic-versioning-50jp"&gt;https://dev.to/aheil/semantic-versioning-50jp&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="https://dev.to/luisaugusto/understanding-semantic-versioning-27kf"&gt;https://dev.to/luisaugusto/understanding-semantic-versioning-27kf&lt;/a&gt;&lt;/p&gt;

</description>
      <category>terraform</category>
      <category>semver</category>
      <category>hashicorp</category>
    </item>
    <item>
      <title>Cohesion and Coupling for Secrets Management in CI/CD Work Flows</title>
      <dc:creator>🦄N B🛡</dc:creator>
      <pubDate>Mon, 11 May 2020 21:59:09 +0000</pubDate>
      <link>https://dev.to/digitalonus/cohesion-and-coupling-for-secrets-management-in-ci-cd-work-flows-1m83</link>
      <guid>https://dev.to/digitalonus/cohesion-and-coupling-for-secrets-management-in-ci-cd-work-flows-1m83</guid>
      <description>&lt;p&gt;TL;DR: If you couple your some other deployment process to your Secrets Management, then you would have to redeploy for new creds. And that's &lt;strong&gt;bad&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;There are a few "tight couplings" to avoid for Secrets Management:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Coupling to Infrastructure as Code (IaC)&lt;/li&gt;
&lt;li&gt;Coupling to Configuration as Code (CaC)&lt;/li&gt;
&lt;li&gt;Coupling to Application Deployment (CI/CD)&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;The test is, if I need to do an emergency revocation, do I have to wait for any of the above to complete?&lt;/p&gt;

&lt;p&gt;For example, if you happen to be using git2consul for secrets management*, used in one of the above 3 systems, is the only way to update secrets, then you have to wait for a deployment for one of the above to complete. If the lack of those credentials is what's causing the problem in the first place, or the build happens to be broken at the same time as the emergency revocation occurs, you'd be in trouble. &lt;/p&gt;

&lt;p&gt;A kinder, gentler way to decouple these work flows from Secrets Management? You could ensure that Consul could be edited directly for emergency.  While still having a git2consul pipeline for the configs.&lt;/p&gt;

&lt;p&gt;If you are generating database creds, and giving them to the application, that isn’t dynamic any longer as the application can not generate them but now receives them.&lt;/p&gt;

&lt;p&gt;As long as git2consul isn't the only way to revoke / re-issue creds, I think that makes a lot of sense.&lt;/p&gt;

&lt;p&gt;*If you have HashiCorp Vault available, it may be &lt;a href="https://github.com/breser/git2consul/issues/134"&gt;better to consider Vault for this&lt;/a&gt;, especially since Vault works with &lt;code&gt;consul-template&lt;/code&gt;, or better yet &lt;code&gt;envconsul&lt;/code&gt; or &lt;a href="https://www.vaultproject.io/docs/agent/"&gt;Vault Agent&lt;/a&gt;.&lt;/p&gt;

</description>
      <category>secretsmanagement</category>
      <category>architecture</category>
      <category>coupling</category>
      <category>informationsecurity</category>
    </item>
    <item>
      <title>IAM vs PIM vs PAM vs HashiCorp Vault vs Skub in 20 seconds</title>
      <dc:creator>🦄N B🛡</dc:creator>
      <pubDate>Fri, 06 Mar 2020 04:01:50 +0000</pubDate>
      <link>https://dev.to/digitalonus/iam-vs-pim-vs-pam-vs-hashicorp-vault-vs-skub-in-20-seconds-486b</link>
      <guid>https://dev.to/digitalonus/iam-vs-pim-vs-pam-vs-hashicorp-vault-vs-skub-in-20-seconds-486b</guid>
      <description>&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--Ju_tTOKy--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_66%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/i/966ged2tw2j382gz6lnq.gif" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--Ju_tTOKy--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_66%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/i/966ged2tw2j382gz6lnq.gif" alt="This image has nothing to do with PIM vs PAM, but it's funny, I guess. And dammit my blog post needs an image!"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Here's the answer in 10 seconds of video (2:03 to 2:13): &lt;a href="https://youtu.be/cVYSc2d6Gco?t=123"&gt;https://youtu.be/cVYSc2d6Gco?t=123&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;But, because that's not long enough for a "real" blog post, I'll ramble on a bit more. &lt;/p&gt;

&lt;p&gt;The big difference is machine identity vs human identity. And Dynamic Secrets Management vs Password/Privileged Access Management.&lt;/p&gt;

&lt;p&gt;In a couple of sales conversations I've come across this question: &lt;/p&gt;

&lt;p&gt;"What's the difference between Vault Enterprise and Traditional Privilege Access Management?"&lt;/p&gt;

&lt;p&gt;Those of us who call ourselves Vault Nerds should all have a quick answer to this, because it's a high level question involving addressable markets for Services companies, and HashiCorp's product placement.&lt;/p&gt;

&lt;p&gt;And here's a 5 minute talk by the HashiCorp founders about the difference between Identity and Access Management (IAM) and Privileged Access Management (PAM): &lt;a href="https://youtu.be/x4Wf2W3Wl4w?t=117"&gt;https://youtu.be/x4Wf2W3Wl4w?t=117&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Again, that link will jump you to the most important 10 seconds of video.&lt;/p&gt;

&lt;p&gt;Anyway, now that I've told you where they're different, where's the overlap?&lt;/p&gt;

&lt;p&gt;Why isn't there one tool or platform capable of handling both?&lt;/p&gt;

&lt;p&gt;Well, perhaps changing direction from the clear distinctions set by Armon, HashiCorp Vault has feature-creeped further into the PIM game: &lt;a href="https://www.vaultproject.io/use-cases/identity-based-access/"&gt;https://www.vaultproject.io/use-cases/identity-based-access/&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;HashiCorp Vault's still not directly competing with the likes of Thycotic, CyberArk, or CA PAM.&lt;/p&gt;

&lt;p&gt;And I wrote up an example of where a platform for "brokering" machine identities can also cover one PAM use case, namely SSH access to a sensitive machine: &lt;a href="https://dev.to/digitalonus/vault-pim-2bp6"&gt;https://dev.to/digitalonus/vault-pim-2bp6&lt;/a&gt;&lt;/p&gt;

</description>
      <category>identity</category>
      <category>hashicorpvault</category>
      <category>pim</category>
      <category>privilege</category>
    </item>
    <item>
      <title>Privileged Identity Management (PIM) with HashiCorp Vault SSH Certificates</title>
      <dc:creator>🦄N B🛡</dc:creator>
      <pubDate>Sat, 22 Feb 2020 00:13:53 +0000</pubDate>
      <link>https://dev.to/digitalonus/vault-pim-2bp6</link>
      <guid>https://dev.to/digitalonus/vault-pim-2bp6</guid>
      <description>&lt;p&gt;Vault's product managers and the HashiCorp founders have, in the past, established a fairly clear difference in the target market and solutions between traditional Privileged Access Management, Secrets Management, and Data Protection.&lt;/p&gt;

&lt;p&gt;Privileged Access Management or Privileged Identity Management, as a use case or solution, refers to delegation of access to human operators, e.g. when a Kubernetes administrator needs to temporarily get access to an Azure account to review logs. &lt;/p&gt;

&lt;p&gt;The Secrets Management use case needs a system to broker access among various systems and the platforms on which they run, e.g. when a Kubernetes Pod needs to access an S3 service. &lt;/p&gt;

&lt;p&gt;Last but, in my view, most important, the Data Protection use case needs a way to set and enforce policy for limiting access to data, typically using cryptography via encryption, or even Encryption as a Service.&lt;/p&gt;

&lt;p&gt;Some examples of cases where HashiCorp representatives have shied away from HashiCorp replacing PAM:&lt;/p&gt;

&lt;p&gt;Vault Identity Design Goals (Note that LDAP Sync is not on the table): &lt;a href="https://www.hashicorp.com/resources/vault-identity-system"&gt;https://www.hashicorp.com/resources/vault-identity-system&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Vault vs Traditional PAM tools: &lt;a href="https://www.hashicorp.com/resources/difference-between-vault-and-traditional-pam"&gt;https://www.hashicorp.com/resources/difference-between-vault-and-traditional-pam&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;That said, HashiCorp has recently begun to pay more attention to Vault's potential to meet a few of the needs of PAM and PIM systems.&lt;/p&gt;

&lt;p&gt;The website vaultproject.io just added PIM as a first class use case, next to Secrets Management and Data Protection: &lt;a href="https://www.vaultproject.io/use-cases/identity-based-access"&gt;https://www.vaultproject.io/use-cases/identity-based-access&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;I'd like to discuss a common PIM scenario, and how developers can, with &lt;em&gt;relative&lt;/em&gt; simplicity adapt a system like Vault to accomplish this.&lt;/p&gt;

&lt;p&gt;Example scenario: I need a developer, named Pedro, to use a read-only user on a host OS whose SSH server trusts an SSH Certificate Authority in Vault.&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;Pedro logs in to the Vault GUI or CLI via SSO, and his policy gets him a 15-minute SSH certificate from the Signed SSH Certificate Secrets Engine.&lt;/p&gt;

&lt;p&gt;Now Pedro can use that fresh 15-minute SSH certificate to log in as the read-only user.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;NOTE: &lt;em&gt;We can also create a user, and give Vault an SSH key for that user, to control single use authentications to servers. Vault would then log every authentication to its audit log. The process is slightly different from this, as it does require the SSH server on the host OS to talk to Vault as part of the SSH server's login flow. The SSH server would ask Vault if Pedro's login is still valid.&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--UHDTXPVo--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/i/dstbqbi3aqr64qm2a0oe.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--UHDTXPVo--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/i/dstbqbi3aqr64qm2a0oe.png" alt="Alt Text"&gt;&lt;/a&gt;&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight"&gt;&lt;pre class="highlight plaintext"&gt;&lt;code&gt;sequenceDiagram
    Admin -&amp;gt;&amp;gt; Vault: Set up SSH Certificate Secrets Engine Role
    Admin -&amp;gt;&amp;gt; Vault: Create Vault Policy which gives access to the above
    Admin -&amp;gt;&amp;gt; Vault: Associate Pedro's AD group with that Vault Policy.
    Admin -&amp;gt;&amp;gt; Ansible: Give Public Key from Vault SSH Certificate Secrets Engine to Ansible
    Ansible -&amp;gt;&amp;gt; RHEL OS: Add pedro user w/limited permissions
    Ansible -&amp;gt;&amp;gt; RHEL OS: Add Public Key from Vault SSH Certificate Secrets Engine Role to SSH Server
    Pedro -&amp;gt;&amp;gt; Vault: Log in with AD credentials
    Vault -&amp;gt;&amp;gt; AD: Get Credential validity and memberships
    Vault -&amp;gt;&amp;gt; Pedro: Vault Token
    Varun -&amp;gt;&amp;gt; Vault: Request SSH Cert using Token
    Vault -&amp;gt;&amp;gt; Pedro: ✓ SSH Cert for pedro user✓ 
    Pedro -&amp;gt;&amp;gt; Vault: Request DB credentials
    Vault -&amp;gt;&amp;gt; Pedro: ❌Permission Denied❌
    Pedro -&amp;gt;&amp;gt; RHEL OS: ssh pedro@RHELOS
    RHEL OS -&amp;gt;&amp;gt; Pedro: ✓ SSH connection✓ 
    Pedro -&amp;gt;&amp;gt; RHEL OS: ls
    Pedro -&amp;gt;&amp;gt; RHEL OS: scp pedro@RHELOS:/home/varun/applog .
    Pedro -&amp;gt;&amp;gt; RHEL OS: systemctl stop consul
    RHEL OS -&amp;gt;&amp;gt; Pedro: ❌Permission Denied❌
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;



&lt;p&gt;Note: &lt;/p&gt;

&lt;p&gt;Vault has some other specific PIM features. &lt;/p&gt;

&lt;p&gt;Active Directory Secret Check-In/Check-Out: In the Active Directory secrets engine, users or applications can check out a service account for use, and its password will be rotated when it's checked back in.&lt;/p&gt;

</description>
      <category>hashicorpvault</category>
      <category>identity</category>
      <category>privilege</category>
      <category>sshcertificates</category>
    </item>
    <item>
      <title>Dealing with Vault Leases via Accessors</title>
      <dc:creator>🦄N B🛡</dc:creator>
      <pubDate>Mon, 23 Sep 2019 21:35:34 +0000</pubDate>
      <link>https://dev.to/digitalonus/dealing-with-vault-leases-via-accessors-53a7</link>
      <guid>https://dev.to/digitalonus/dealing-with-vault-leases-via-accessors-53a7</guid>
      <description>&lt;p&gt;Often, when administering Vault Enterprise, after its deployment, you'll need to configure it.&lt;/p&gt;

&lt;p&gt;Much of the work after designing and planning is configuring Vault Enterprise via its API, or a wrapper of the API.&lt;/p&gt;

&lt;p&gt;However, there come times, especially when troubleshooting or automating something, when an admin of Vault Enterprise has to manage the state within Vault, itself, rather than just the configuration. &lt;/p&gt;

&lt;p&gt;This is especially true if there is a problem, like potential undesired access or application misbehavior.&lt;/p&gt;

&lt;p&gt;What if you want to, as part of an investigation, see all of the currently valid access tokens, Azure Creds, or Database credentials that were created on a specific day?&lt;/p&gt;

&lt;p&gt;I'll show you a script that will do this for you. Before we do that, though, we'll download a binary file to set up a "dummy" Vault to test on. You don't have to install anything, or write any configuration files.&lt;/p&gt;

&lt;p&gt;For some background, I recommend reading about Vault Leases &amp;amp; the leasing "hierarchy" that Vault uses before we go further: &lt;/p&gt;

&lt;p&gt;&lt;a href="https://www.vaultproject.io/guides/identity/lease/"&gt;https://www.vaultproject.io/guides/identity/lease/&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;The documentation might be a bit confusing, but hopefully using it over the course of this guide will make things more clear. &lt;/p&gt;

&lt;h2&gt;
  
  
  Download Vault
&lt;/h2&gt;

&lt;p&gt;We'll download the binary for HashiCorp Vault, because we can use it to run an easy Vault server:&lt;/p&gt;

&lt;p&gt;&lt;a href="https://www.vaultproject.io/downloads.html"&gt;https://www.vaultproject.io/downloads.html&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;After you have downloaded and extracted the binary file, open a Terminal window.&lt;/p&gt;

&lt;h3&gt;
  
  
  If You're on a Mac, Open a Bash Terminal
&lt;/h3&gt;

&lt;p&gt;Open your Applications folder, then Utilities and double-click on Terminal, or press Command + spacebar to launch Spotlight, then type "Terminal", and double-click on the search result. You'll see a small window with a white background open o your desktop.&lt;/p&gt;

&lt;h3&gt;
  
  
  If you're on a Windows OS, Open a Shell Terminal
&lt;/h3&gt;

&lt;p&gt;Open the Run dialog by holding the &lt;code&gt;Windows&lt;/code&gt; key, and pressing R once. Then, enter &lt;code&gt;cmd&lt;/code&gt;. When you press the &lt;code&gt;Enter&lt;/code&gt; key, after entering &lt;code&gt;cmd&lt;/code&gt;, you will see a black window with white text.&lt;/p&gt;

&lt;p&gt;In your shell terminal that you just opened, use the &lt;code&gt;cd&lt;/code&gt; command, along with the &lt;code&gt;dir&lt;/code&gt; or &lt;code&gt;ls&lt;/code&gt; commands, to navigate to where you downloaded Vault.&lt;/p&gt;

&lt;h2&gt;
  
  
  Run a Vault Server
&lt;/h2&gt;

&lt;p&gt;Enter the following in the terminal when you have navigated your terminal to the folder in which you have downloaded and extracted Vault:&lt;/p&gt;

&lt;p&gt;&lt;code&gt;./vault server -dev -dev-root-token-id=root&lt;/code&gt;&lt;/p&gt;

&lt;p&gt;You should see some output, from Vault, but you will not be able to enter more commands in this terminal. &lt;/p&gt;

&lt;p&gt;To keep entering more commands, open another terminal, and navigate to the same folder in which you had downloaded and extracted Vault.&lt;/p&gt;

&lt;h2&gt;
  
  
  Connect to Vault
&lt;/h2&gt;

&lt;p&gt;Mac: &lt;code&gt;export VAULT_TOKEN=root&lt;/code&gt;&lt;br&gt;
&lt;code&gt;export VAULT_ADDR=http://127.0.0.1:8200&lt;/code&gt;&lt;br&gt;
&lt;code&gt;./vault status&lt;/code&gt;&lt;/p&gt;

&lt;p&gt;The last command, the one with &lt;code&gt;status&lt;/code&gt;, should show the status of your Vault. That shows that you can connect to it. &lt;/p&gt;

&lt;h2&gt;
  
  
  Download the script
&lt;/h2&gt;

&lt;p&gt;&lt;code&gt;git clone https://github.com/v6/delete_old_tokens&lt;/code&gt;&lt;br&gt;
&lt;code&gt;cd delete_old_tokens&lt;/code&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  Run the script
&lt;/h2&gt;

&lt;p&gt;&lt;em&gt;(This part might not work on Windows, but please don't let me stop you from converting the code to PowerShell or the like.)&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;&lt;code&gt;./list_accessor_issue_time.sh | grep 2019-09-13&lt;/code&gt;&lt;/p&gt;

&lt;p&gt;If you wanted to search for a different day, say, September 20, 2019, you would run the following, instead: &lt;/p&gt;

&lt;p&gt;&lt;code&gt;./list_accessor_issue_time.sh | grep 2019-09-20&lt;/code&gt;&lt;/p&gt;

</description>
      <category>vaultenterprise</category>
    </item>
  </channel>
</rss>
