Skip to content

Instantly share code, notes, and snippets.

Alexander Casm82

  • Russia, Izhevsk
Block or report user

Report or block Casm82

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
View krb_test.js
const kerberos = require("kerberos");
const krbSvc = "HTTP@centos.domain.org";
const SegfaultHandler = require('segfault-handler');
SegfaultHandler.registerHandler("crash.log");
let ticket = "YIIGoAYGKwYBBQUCoIIGlDCCBpCgMDAuBgkqhkiC9xIBAgIGCSqGSIb3EgECAgYKKwYBBAGCNwICHgYKKwYBBAGCNwICCqKCBloEggZWYIIGUgYJKoZIhvcSAQICAQBuggZBMIIGPaADAgEFoQMCAQ6iBwMFACAAAACjggR5YYIEdTCCBHGgAwIBBaEMGwpET01BSU4uT1JHoiQwIqADAgECoRswGRsESFRUUBsRY2VudG9zLmRvbWFpbi5vcmejggQ0MIIEMKADAgEXoQMCAQOiggQiBIIEHiB17oIo1fAAIPadrXHY110ZxWvvbem7SazIML5LtDd4RxfIXttvpuYjfMzXT2u8AkiKDN35rYAZ6OAFzts1VuRrnNQLv5/bat4kwSn+B0jf7ZBl4EFW7iewR+9KsvTHdJiWYRjVTyoHSkqKil57U4UxrSmNzCrYDQooa4a5gGhx4nCfZw6MhdzNyfnoNDDDvTWcRi1GXoSDCKXq64S3sYxHH+wz6QF+t20EqlJah+GCEslazt4ubjxhV3G9QuLdbixceTGaDNWxjG3o3MNlfwPWTm0PQElCm3Uq7+dgbIyYBEvublPqgmUolSP+AADQjzozucy4/O+mqYoHsuE0jnDd/uSf+iBHu7r3QAdMtJMjY8znRxhef0RqHWw5z/u0/6W8Z+ATUFkF5M/G8E17IN/yBrqbW+goyIAqL260PHulAuFvCW9U60zUEj7ikJ53PFX/dz0aHnGIOHmbuFOIKXpunXkbuAfsPM5xrPza3Shht4WFDTBv3ieTMKOhocNcPReF2B4EyoTL0J9505DXl1ZKH8IvNF
View gdb_node_krb.log
[node@centos krbAuth]$ gdb --args /opt/node-debug/bin/node krb_test.js
GNU gdb (GDB) Red Hat Enterprise Linux 7.6.1-114.el7
Copyright (C) 2013 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law. Type "show copying"
and "show warranty" for details.
This GDB was configured as "x86_64-redhat-linux-gnu".
For bug reporting instructions, please see:
<http://www.gnu.org/software/gdb/bugs/>...
View krb_node_inspect.log
break in file:///home/node/krbAuth/krb_test.js:14
12 if (err) console.error(err);
13 //check ticket
>14 krbServer.step(ticket, function(err) {
15 if (err) console.error(err);
16 console.log(krbServer);
debug> n
< PID 20487 received SIGSEGV for address: 0x75
View krb_example_debug.js
const kerberos = require("kerberos");
const express = require("express");
const app = express();
const krbSvc = "HTTP@centos.domain.org";
const SegfaultHandler = require('segfault-handler');
SegfaultHandler.registerHandler("crash.log");
app.get('/', function (req, res) {
console.log('-----request-----');
View krb_example.js
const kerberos = require("kerberos");
const express = require("express");
const app = express();
const krbSvc = "HTTP@centos.domain.org";
app.get('/', function (req, res) {
console.log('-----request-----');
console.log(req.headers);
if (!req.headers.authorization) {
View node_run_7.6.txt
[node@centos7.6 krbAuth]$ export KRB5_KTNAME=/srv/keytabs/krbAuth.keytab
[node@centos7.6 krbAuth]$ klist -k /srv/keytabs/krbAuth.keytab
Keytab name: FILE:/srv/keytabs/krbAuth.keytab
KVNO Principal
---- --------------------------------------------------------------------------
32 HTTP/centos.domain.org@DOMAIN.ORG
[node@centos7.6 krbAuth]$ node krb_example.js
-----request-----
View node_run_7.5.txt
[node@centos7.5 lkrbAuth]$ export KRB5_KTNAME=/srv/keytabs/krbAuth.keytab
[node@centos7.5 krbAuth]$ klist -k /srv/keytabs/krbAuth.keytab
Keytab name: FILE:/srv/keytabs/krbAuth.keytab
KVNO Principal
---- --------------------------------------------------------------------------
32 HTTP/centos.domain.org@DOMAIN.ORG
[node@centos7.5 krbAuth]$ node krb_example.js
-----request-----
View ldd_7.6.txt
[node@centos7.6 ~]$ cat /etc/centos-release
CentOS Linux release 7.6.1810 (Core)
[node@centos7.6 Release]$ ldd kerberos.node
linux-vdso.so.1 => (0x00007ffcaeff1000)
libkrb5.so.3 => /lib64/libkrb5.so.3 (0x00007f9d6a118000)
libgssapi_krb5.so.2 => /lib64/libgssapi_krb5.so.2 (0x00007f9d69ecb000)
libstdc++.so.6 => /lib64/libstdc++.so.6 (0x00007f9d69bc4000)
libm.so.6 => /lib64/libm.so.6 (0x00007f9d698c2000)
libgcc_s.so.1 => /lib64/libgcc_s.so.1 (0x00007f9d696ac000)
View ldd_7.5.txt
[node@centos7.5 ~]$ cat /etc/centos-release
CentOS Linux release 7.5.1804 (Core)
[node@centos7.5 Release]$ ldd kerberos.node
linux-vdso.so.1 => (0x00007ffdff897000)
libkrb5.so.3 => /lib64/libkrb5.so.3 (0x00007f9d750ab000)
libgssapi_krb5.so.2 => /lib64/libgssapi_krb5.so.2 (0x00007f9d74e5e000)
libstdc++.so.6 => /lib64/libstdc++.so.6 (0x00007f9d74b57000)
libm.so.6 => /lib64/libm.so.6 (0x00007f9d74855000)
@Casm82
Casm82 / 2016-06-19.xmlconsole.xml
Created Sep 3, 2016
XML-console log Vacuum-IM 19-06-2016 build
View 2016-06-19.xmlconsole.xml
>>>> userid1@jabber.domain.ru/TEST-WIN 15:05:46 +0 >>>>
<stream:stream xmlns:stream="http://etherx.jabber.org/streams" version="1.0" xmlns="jabber:client" xmlns:xml="http://www.w3.org/XML/1998/namespace" xml:lang="ru_RU" to="jabber.domain.ru"/>
<<<< userid1@jabber.domain.ru/TEST-WIN 15:05:46 +16 <<<<
<stream:stream xmlns:stream="http://etherx.jabber.org/streams" version="1.0" xmlns="jabber:client" from="jabber.domain.ru" id="7ob4fk065e" to="userid1@jabber.domain.ru/TEST-WIN" xml:lang="und" xmlns:xml="http://www.w3.org/XML/1998/namespace"/>
<<<< userid1@jabber.domain.ru/TEST-WIN 15:05:46 +62 <<<<
<stream:features xmlns:stream="http://etherx.jabber.org/streams" to="userid1@jabber.domain.ru/TEST-WIN">
<starttls xmlns="urn:ietf:params:xml:ns:xmpp-tls"/>
<mechanisms xmlns="urn:ietf:params:xml:ns:xmpp-sasl">
You can’t perform that action at this time.