Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Improve certificate logging #254

Open
wants to merge 8 commits into
base: v1.x/staging
Choose a base branch
from

Conversation

timgerstel
Copy link
Contributor

@timgerstel timgerstel commented Oct 14, 2020

Output example in log:

2020-10-16 03:14:32.212 <ZWED:21144> tgerstel DEBUG (_zsf.network,webserver.js:203) ZWED0072I - Using Certificate: {
  "signature": "w))Í�QI³©±�\u000fÐâö«�Rlx\u0013\u001dY}(ÕïïEªié� \u0012O��:�\u001fxfÈ7\u0014ÊÞPÍñÍÂí¸×þÛ³;{?jHX\u0018þ�ª¯¨®�ýÕÂ�6º�*Â�,¾]zì¶#pZ´[\u0016\b�ÉÞ�1o\ta�f·VSðÒ�ï�A�\u0016¸1G\u0005Mgb¸Do'½¦ï}W6¤:l\u0006¥Ï\tf´Ì(�î±µÖ¶E{ß��?gò�È~�ã��ø$µ3×/��M=á£ù[\u0015(TÚÎ\u0011?Oz=��Ì èô�´²m¼¿õü\u0000å¥5)À`À-�¹�s\u0010�¢H�»ÚöhÿÞ;*þÜb�\u0013¸ñ^ôF-p\u0003õ�(�\u0015­�O>\r]Â/",
  "validity": {
    "notBefore": "2018-11-29T12:27:01.000Z",
    "notAfter": "2028-11-26T12:27:01.000Z"
  },
  "issuer": {
    "attributes": [
      {
        "type": "2.5.4.6",
        "value": "CZ",
        "valueTagClass": 19,
        "name": "countryName",
        "shortName": "C"
      },
      {
        "type": "2.5.4.8",
        "value": "Prague",
        "valueTagClass": 19,
        "name": "stateOrProvinceName",
        "shortName": "ST"
      },
      {
        "type": "2.5.4.7",
        "value": "Prague",
        "valueTagClass": 19,
        "name": "localityName",
        "shortName": "L"
      },
      {
        "type": "2.5.4.10",
        "value": "Zowe Sample",
        "valueTagClass": 19,
        "name": "organizationName",
        "shortName": "O"
      },
      {
        "type": "2.5.4.11",
        "value": "API Mediation Layer",
        "valueTagClass": 19,
        "name": "organizationalUnitName",
        "shortName": "OU"
      },
      {
        "type": "2.5.4.3",
        "value": "Zowe Development Instances Certificate Authority",
        "valueTagClass": 19,
        "name": "commonName",
        "shortName": "CN"
      }
    ],
    "hash": "a5f44b9791707096a3380cc2c03f7c7d205834ce"
  },
  "extensions": [
    {
      "id": "2.5.29.35",
      "critical": false,
      "value": "0\u0016�\u0014P¾\bïò�§o ,,�°� ¥÷ÐmÓ",
      "name": "authorityKeyIdentifier"
    },
    {
      "id": "2.5.29.37",
      "critical": false,
      "value": "0\u0014\u0006\b+\u0006\u0001\u0005\u0005\u0007\u0003\u0002\u0006\b+\u0006\u0001\u0005\u0005\u0007\u0003\u0001",
      "name": "extKeyUsage",
      "clientAuth": true,
      "serverAuth": true
    },
    {
      "id": "2.5.29.15",
      "critical": true,
      "value": "\u0003\u0002\u0004ð",
      "name": "keyUsage",
      "digitalSignature": true,
      "nonRepudiation": true,
      "keyEncipherment": true,
      "dataEncipherment": true,
      "keyAgreement": false,
      "keyCertSign": false,
      "cRLSign": false,
      "encipherOnly": false,
      "decipherOnly": false
    },
    {
      "id": "2.5.29.17",
      "critical": false,
      "value": "0\"�\u0015localhost.localdomain�\tlocalhost",
      "name": "subjectAltName",
      "altNames": [
        {
          "type": 2,
          "value": "localhost.localdomain"
        },
        {
          "type": 2,
          "value": "localhost"
        }
      ]
    },
    {
      "id": "2.5.29.14",
      "critical": false,
      "value": "\u0004\u0014Ö\u000f<\nõ�Ë%M)fàä�ËÒtèÐk",
      "name": "subjectKeyIdentifier",
      "subjectKeyIdentifier": "d60f3c0af585cb254d2966e0e49bcbd274e8d06b"
    }
  ],
  "publicKey": {
    "n": {
      "data": [
        141479335,
        146269757,
        160325756,
        204577819,
        199843448,
        89935110,
        246398031,
        36916853,
        49319164,
        207689771,
        53932336,
        60662260,
        140326609,
        4643810,
        91794259,
        60571500,
        69945039,
        72931535,
        154318972,
        32632003,
        7627895,
        607289,
        100910188,
        238488585,
        191691404,
        94179501,
        80070000,
        186870292,
        252711605,
        38611416,
        251680737,
        31715492,
        170769423,
        106604843,
        101599054,
        173403085,
        73966867,
        108853980,
        197106923,
        263804788,
        134178335,
        34659391,
        36075785,
        247061199,
        97106269,
        109603930,
        197101407,
        53189259,
        65780008,
        258176253,
        237442364,
        228528956,
        88124429,
        104418010,
        51157526,
        74402592,
        256424455,
        141183046,
        49820210,
        52734581,
        199660983,
        84145920,
        117665497,
        153653740,
        95006458,
        98290287,
        76670330,
        6849300,
        201422090,
        40213483,
        258024089,
        152571130,
        13163199,
        8
      ],
      "t": 74,
      "s": 0
    },
    "e": {
      "data": [
        65537
      ],
      "t": 1,
      "s": 0
    }
  }
}

Timothy Gerstel added 3 commits October 14, 2020 02:03
Signed-off-by: Timothy Gerstel <tgerstel@rocketsoftware.com>
Signed-off-by: Timothy Gerstel <tgerstel@rocketsoftware.com>
Signed-off-by: Timothy Gerstel <tgerstel@rocketsoftware.com>
@timgerstel timgerstel changed the title [WIP] External CA Certificates Fix [WIP] Improve certificate logging Oct 15, 2020
Timothy Gerstel added 2 commits October 15, 2020 14:30
Signed-off-by: Timothy Gerstel <tgerstel@rocketsoftware.com>
Signed-off-by: Timothy Gerstel <tgerstel@rocketsoftware.com>
Timothy Gerstel added 2 commits October 15, 2020 23:03
Signed-off-by: Timothy Gerstel <tgerstel@rocketsoftware.com>
Signed-off-by: Timothy Gerstel <tgerstel@rocketsoftware.com>
@timgerstel timgerstel marked this pull request as ready for review October 16, 2020 03:12
Signed-off-by: Timothy Gerstel <tgerstel@rocketsoftware.com>
@timgerstel timgerstel changed the title [WIP] Improve certificate logging Improve certificate logging Oct 16, 2020
@sonarcloud
Copy link

sonarcloud bot commented Oct 16, 2020

SonarCloud Quality Gate failed.

Bug C 2 Bugs
Vulnerability A 0 Vulnerabilities (and Security Hotspot 0 Security Hotspots to review)
Code Smell A 13 Code Smells

0.0% 0.0% Coverage
4.3% 4.3% Duplication

warning The version of Java (1.8.0_242) you have used to run this analysis is deprecated and we will stop accepting it from October 2020. Please update to at least Java 11.
Read more here
warning The version of Node.js (v8.17.0) you have used to run this analysis is deprecated and we will stop accepting it from 16th November 2020. Please update to at least Node.js 10. Read more here

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: Ready for Review
Development

Successfully merging this pull request may close these issues.

1 participant