Toggle navigation
Toggle navigation
This project
Loading...
Sign in
오세헌
/
Ingredient-to-Dish-ChatBot
Go to a project
Toggle navigation
Toggle navigation pinning
Projects
Groups
Snippets
Help
Project
Activity
Repository
Pipelines
Graphs
Issues
0
Merge Requests
0
Wiki
Snippets
Network
Create a new issue
Builds
Commits
Issue Boards
Authored by
오세헌
2022-05-29 20:08:25 +0900
Browse Files
Options
Browse Files
Download
Email Patches
Plain Diff
Commit
9fa45f8221ef82577e416d32b6aaf48d3ad8e3aa
9fa45f82
0 parents
base source code
Hide whitespace changes
Inline
Side-by-side
Showing
56 changed files
with
3731 additions
and
0 deletions
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/.gitignore
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/express/assignments/assignment01/app.js
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/express/assignments/assignment01/package.json
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/express/assignments/assignment02/app.js
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/express/assignments/assignment02/package.json
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/express/tutorials/approute/app.js
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/express/tutorials/approute/package.json
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/express/tutorials/expressrouter/app.js
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/express/tutorials/expressrouter/birds.js
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/express/tutorials/expressrouter/package.json
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/express/tutorials/helloworld/app.js
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/express/tutorials/helloworld/package.json
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/express/tutorials/multiplehandler/app.js
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/express/tutorials/multiplehandler/package.json
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/express/tutorials/render/app.js
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/express/tutorials/render/package.json
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/express/tutorials/render/views/index.ejs
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/express/tutorials/routeparameter/app.js
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/express/tutorials/routeparameter/package.json
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/express/tutorials/routingpath/app.js
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/express/tutorials/routingpath/package.json
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/express/tutorials/session/app.js
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/express/tutorials/session/package.json
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/express/tutorials/simplerouting/app.js
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/express/tutorials/simplerouting/package.json
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/express/tutorials/specialrouting/app.js
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/express/tutorials/specialrouting/package.json
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/express/tutorials/staticfiles/app.js
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/express/tutorials/staticfiles/package.json
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/express/tutorials/staticfiles/public/icon.png
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/express/tutorials/staticfiles/public/index.html
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/messenger/notify/app.js
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/messenger/notify/package-lock.json
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/messenger/notify/package.json
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/messenger/push/app.js
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/messenger/push/package-lock.json
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/messenger/push/package.json
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/messenger/reply/app.js
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/messenger/reply/package-lock.json
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/messenger/reply/package.json
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/messenger/ssl/app.js
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/messenger/ssl/package-lock.json
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/messenger/ssl/package.json
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/messenger/trans/app.js
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/messenger/trans/package-lock.json
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/messenger/trans/package.json
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/messenger/webhook/app.js
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/messenger/webhook/package-lock.json
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/messenger/webhook/package.json
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/nodejs/Assignments/01/app.js
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/nodejs/Assignments/01/mymodule.js
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/nodejs/Assignments/02/index.js
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/nodejs/Tutorial/event01/app.js
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/nodejs/Tutorial/event02/app.js
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/nodejs/Tutorial/mymodule/app.js
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/nodejs/Tutorial/mymodule/mymodule.js
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/.gitignore
0 → 100644
View file @
9fa45f8
node_modules
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/express/assignments/assignment01/app.js
0 → 100644
View file @
9fa45f8
let
express
=
require
(
'express'
);
let
app
=
express
();
let
bodyParser
=
require
(
'body-parser'
);
app
.
use
(
bodyParser
.
urlencoded
({
extended
:
false
}));
app
.
use
(
bodyParser
.
json
());
let
books
=
new
Array
();
app
.
get
(
'/books/:bookId'
,
(
req
,
res
)
=>
{
let
bookId
=
req
.
params
.
bookId
;
console
.
log
(
books
[
bookId
]);
res
.
send
(
books
[
bookId
]);
});
/*
* json representation of book object
{
"id" : 2,
"name" : "book2",
"price" : 2000,
"author" : "jin"
}
*/
app
.
post
(
'/books'
,
(
req
,
res
)
=>
{
// Create book information
books
[
req
.
body
.
id
]
=
[
req
.
body
.
id
,
req
.
body
.
name
,
req
.
body
.
price
,
req
.
body
.
author
];
res
.
send
(
books
[
req
.
body
.
id
]);
})
app
.
put
(
'/books'
,
(
req
,
res
)
=>
{
// Update book information
})
app
.
delete
(
'/books/:bookId'
,
(
req
,
res
)
=>
{
// Delete book information
})
let
server
=
app
.
listen
(
80
);
console
.
log
(
books
);
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/express/assignments/assignment01/package.json
0 → 100644
View file @
9fa45f8
{
"name"
:
"assignment01"
,
"version"
:
"1.0.0"
,
"description"
:
""
,
"main"
:
"index.js"
,
"scripts"
:
{
"test"
:
"echo
\"
Error: no test specified
\"
&& exit 1"
},
"author"
:
""
,
"license"
:
"ISC"
,
"dependencies"
:
{
"body-parser"
:
"^1.17.1"
,
"express"
:
"^4.15.2"
}
}
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/express/assignments/assignment02/app.js
0 → 100644
View file @
9fa45f8
let
express
=
require
(
'express'
);
let
app
=
express
();
let
bodyParser
=
require
(
'body-parser'
);
let
session
=
require
(
'express-session'
)
app
.
use
(
session
({
secret
:
'keyboard cat'
,
cookie
:
{
maxAge
:
60000
}}))
app
.
use
(
bodyParser
.
urlencoded
({
extended
:
false
}));
app
.
use
(
bodyParser
.
json
());
let
users
=
new
Array
();
users
[
0
]
=
{
"userId"
:
0
,
"name"
:
"jin"
,
"password"
:
"abc"
,
"isAdmin"
:
true
}
app
.
put
(
'/login'
,
(
req
,
res
)
=>
{
// users 배열에서 찾도록 처리 해야 함
// admin 여부를 확인하여 체크
// req.body.id : ID
// req.body.name : 패스워드
res
.
send
(
"Login"
);
});
app
.
put
(
'/logout'
,
(
req
,
res
)
=>
{
// Logout
// 세션 유효 여부를 체크하고 세션 Delete
req
.
session
.
userId
=
null
;
res
.
send
(
"LogOut"
);
});
let
auth
=
(
req
,
res
,
next
)
=>
{
// Session Check
// 어드민 여부 체크 필요
if
(
req
.
session
.
userId
!=
null
)
next
();
else
res
.
send
(
"Error"
);
};
app
.
get
(
'/user/:userId'
,
auth
,
(
req
,
res
)
=>
{
// get User Information
res
.
send
(
"OK"
);
});
// 사용자 추가 시에 admin 여부도 추가해야 함
let
server
=
app
.
listen
(
80
);
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/express/assignments/assignment02/package.json
0 → 100644
View file @
9fa45f8
{
"name"
:
"assignment02"
,
"version"
:
"1.0.0"
,
"description"
:
""
,
"main"
:
"index.js"
,
"scripts"
:
{
"test"
:
"echo
\"
Error: no test specified
\"
&& exit 1"
},
"author"
:
""
,
"license"
:
"ISC"
,
"dependencies"
:
{
"body-parser"
:
"^1.17.1"
,
"express"
:
"^4.15.2"
,
"express-session"
:
"^1.15.2"
}
}
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/express/tutorials/approute/app.js
0 → 100644
View file @
9fa45f8
var
express
=
require
(
'express'
);
var
app
=
express
();
app
.
get
(
'/'
,
function
(
req
,
res
)
{
res
.
send
(
'hello world'
);
})
app
.
route
(
'/book'
)
.
get
(
function
(
req
,
res
)
{
res
.
send
(
'Get a random book'
);
})
.
post
(
function
(
req
,
res
)
{
res
.
send
(
'Add a book'
);
})
.
put
(
function
(
req
,
res
)
{
res
.
send
(
'Update the book'
);
});
var
server
=
app
.
listen
(
23023
);
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/express/tutorials/approute/package.json
0 → 100644
View file @
9fa45f8
{
"name"
:
"approute"
,
"version"
:
"1.0.0"
,
"description"
:
""
,
"main"
:
"index.js"
,
"scripts"
:
{
"test"
:
"echo
\"
Error: no test specified
\"
&& exit 1"
},
"author"
:
""
,
"license"
:
"ISC"
,
"dependencies"
:
{
"express"
:
"^4.15.2"
}
}
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/express/tutorials/expressrouter/app.js
0 → 100644
View file @
9fa45f8
var
express
=
require
(
'express'
);
var
app
=
express
();
var
birds
=
require
(
'./birds'
);
app
.
get
(
'/'
,
function
(
req
,
res
)
{
res
.
send
(
'hello world'
);
})
app
.
use
(
'/birds'
,
birds
);
var
server
=
app
.
listen
(
23023
);
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/express/tutorials/expressrouter/birds.js
0 → 100644
View file @
9fa45f8
var
express
=
require
(
'express'
);
var
router
=
express
.
Router
();
router
.
get
(
'/'
,
function
(
req
,
res
)
{
res
.
send
(
'Birds home page'
);
})
router
.
get
(
'/about'
,
function
(
req
,
res
)
{
res
.
send
(
'About birds'
);
});
module
.
exports
=
router
;
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/express/tutorials/expressrouter/package.json
0 → 100644
View file @
9fa45f8
{
"name"
:
"expressrouter"
,
"version"
:
"1.0.0"
,
"description"
:
""
,
"main"
:
"index.js"
,
"scripts"
:
{
"test"
:
"echo
\"
Error: no test specified
\"
&& exit 1"
},
"author"
:
""
,
"license"
:
"ISC"
,
"dependencies"
:
{
"express"
:
"^4.15.2"
}
}
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/express/tutorials/helloworld/app.js
0 → 100644
View file @
9fa45f8
var
express
=
require
(
'express'
);
var
app
=
express
();
app
.
get
(
'/'
,
function
(
req
,
res
)
{
res
.
send
(
'Hello World'
);
})
var
server
=
app
.
listen
(
23023
,
function
()
{
var
host
=
server
.
address
().
address
var
port
=
server
.
address
().
port
console
.
log
(
"Example app listening at http://%s:%s"
,
host
,
port
)
})
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/express/tutorials/helloworld/package.json
0 → 100644
View file @
9fa45f8
{
"name"
:
"helloworld"
,
"version"
:
"1.0.0"
,
"description"
:
""
,
"main"
:
"index.js"
,
"scripts"
:
{
"test"
:
"echo
\"
Error: no test specified
\"
&& exit 1"
},
"author"
:
""
,
"license"
:
"ISC"
,
"dependencies"
:
{
"express"
:
"^4.15.2"
}
}
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/express/tutorials/multiplehandler/app.js
0 → 100644
View file @
9fa45f8
var
express
=
require
(
'express'
);
var
app
=
express
();
app
.
get
(
'/b'
,
function
(
req
,
res
,
next
)
{
console
.
log
(
'the response will be sent by the next function ...'
)
next
()
},
function
(
req
,
res
)
{
res
.
send
(
'Hello from B!'
)
})
var
cb0
=
function
(
req
,
res
,
next
)
{
console
.
log
(
"call by cb0"
);
next
()
}
var
cb1
=
function
(
req
,
res
,
next
)
{
console
.
log
(
"call by cb1"
);
res
.
send
(
'Hello from C!'
)
}
app
.
get
(
'/c'
,
[
cb0
,
cb1
])
var
server
=
app
.
listen
(
23023
);
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/express/tutorials/multiplehandler/package.json
0 → 100644
View file @
9fa45f8
{
"name"
:
"multiplehandler"
,
"version"
:
"1.0.0"
,
"description"
:
""
,
"main"
:
"index.js"
,
"scripts"
:
{
"test"
:
"echo
\"
Error: no test specified
\"
&& exit 1"
},
"author"
:
""
,
"license"
:
"ISC"
,
"dependencies"
:
{
"express"
:
"^4.15.2"
}
}
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/express/tutorials/render/app.js
0 → 100644
View file @
9fa45f8
var
express
=
require
(
'express'
);
var
app
=
express
();
app
.
set
(
'view engine'
,
'ejs'
);
app
.
set
(
'views'
,
'views'
);
app
.
get
(
'/'
,
function
(
req
,
res
)
{
res
.
render
(
'index'
,
{
title
:
'OSS Page'
});
});
var
server
=
app
.
listen
(
23023
);
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/express/tutorials/render/package.json
0 → 100644
View file @
9fa45f8
{
"name"
:
"render"
,
"version"
:
"1.0.0"
,
"description"
:
""
,
"main"
:
"index.js"
,
"scripts"
:
{
"test"
:
"echo
\"
Error: no test specified
\"
&& exit 1"
},
"author"
:
""
,
"license"
:
"ISC"
,
"dependencies"
:
{
"ejs"
:
"^2.5.6"
,
"express"
:
"^4.15.2"
}
}
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/express/tutorials/render/views/index.ejs
0 → 100644
View file @
9fa45f8
html>
<body>
<%= title %>
</body>
</html>
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/express/tutorials/routeparameter/app.js
0 → 100644
View file @
9fa45f8
var
express
=
require
(
'express'
);
var
app
=
express
();
app
.
get
(
'/users/:userId/books/:bookId'
,
function
(
req
,
res
)
{
res
.
send
(
req
.
params
);
})
var
server
=
app
.
listen
(
23023
);
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/express/tutorials/routeparameter/package.json
0 → 100644
View file @
9fa45f8
{
"name"
:
"routeparameter"
,
"version"
:
"1.0.0"
,
"description"
:
""
,
"main"
:
"index.js"
,
"scripts"
:
{
"test"
:
"echo
\"
Error: no test specified
\"
&& exit 1"
},
"author"
:
""
,
"license"
:
"ISC"
,
"dependencies"
:
{
"express"
:
"^4.15.2"
}
}
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/express/tutorials/routingpath/app.js
0 → 100644
View file @
9fa45f8
var
express
=
require
(
'express'
);
var
app
=
express
();
// The routing path matches requests to /about
app
.
get
(
'/about'
,
function
(
req
,
res
)
{
res
.
send
(
'about'
)
})
// The routing path matches requests to /random.text
app
.
get
(
'/random.text'
,
function
(
req
,
res
)
{
res
.
send
(
'random.text'
)
})
// This route path matches abcd, abxcd, abRANDOMcd, ab123cd, and so on.
app
.
get
(
'/ab*cd'
,
function
(
req
,
res
)
{
res
.
send
(
'ab*cd'
)
})
var
server
=
app
.
listen
(
23023
);
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/express/tutorials/routingpath/package.json
0 → 100644
View file @
9fa45f8
{
"name"
:
"routingpath"
,
"version"
:
"1.0.0"
,
"description"
:
""
,
"main"
:
"index.js"
,
"scripts"
:
{
"test"
:
"echo
\"
Error: no test specified
\"
&& exit 1"
},
"author"
:
""
,
"license"
:
"ISC"
,
"dependencies"
:
{
"express"
:
"^4.15.2"
}
}
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/express/tutorials/session/app.js
0 → 100644
View file @
9fa45f8
var
express
=
require
(
'express'
);
var
app
=
express
();
var
session
=
require
(
'express-session'
)
app
.
use
(
session
({
secret
:
'keyboard cat'
,
cookie
:
{
maxAge
:
60000
}}))
app
.
get
(
'/'
,
function
(
req
,
res
,
next
)
{
var
sess
=
req
.
session
;
console
.
log
(
req
.
session
);
if
(
sess
.
views
)
{
sess
.
views
++
;
res
.
send
(
"session Views "
+
sess
.
views
);
res
.
send
();
}
else
{
req
.
session
.
views
=
1
;
res
.
send
(
"welcome to the session demo. refresh!"
);
res
.
end
();
}
});
var
server
=
app
.
listen
(
23023
);
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/express/tutorials/session/package.json
0 → 100644
View file @
9fa45f8
{
"name"
:
"session"
,
"version"
:
"1.0.0"
,
"description"
:
""
,
"main"
:
"index.js"
,
"scripts"
:
{
"test"
:
"echo
\"
Error: no test specified
\"
&& exit 1"
},
"author"
:
""
,
"license"
:
"ISC"
,
"dependencies"
:
{
"express"
:
"^4.15.2"
,
"express-session"
:
"^1.15.2"
}
}
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/express/tutorials/simplerouting/app.js
0 → 100644
View file @
9fa45f8
var
express
=
require
(
'express'
);
var
app
=
express
();
app
.
get
(
'/'
,
function
(
req
,
res
)
{
res
.
send
(
'hello world'
);
})
var
server
=
app
.
listen
(
23023
);
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/express/tutorials/simplerouting/package.json
0 → 100644
View file @
9fa45f8
{
"name"
:
"simplerouting"
,
"version"
:
"1.0.0"
,
"description"
:
""
,
"main"
:
"index.js"
,
"scripts"
:
{
"test"
:
"echo
\"
Error: no test specified
\"
&& exit 1"
},
"author"
:
""
,
"license"
:
"ISC"
,
"dependencies"
:
{
"express"
:
"^4.15.2"
}
}
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/express/tutorials/specialrouting/app.js
0 → 100644
View file @
9fa45f8
var
express
=
require
(
'express'
);
var
app
=
express
();
app
.
all
(
'/'
,
function
(
req
,
res
,
next
)
{
console
.
log
(
'Accessing the secret section ...'
)
next
()
// pass control to the next handler
})
app
.
get
(
'/'
,
function
(
req
,
res
)
{
res
.
send
(
'hello world'
);
})
app
.
post
(
'/'
,
function
(
req
,
res
)
{
res
.
send
(
'POST request to the homepage'
)
})
var
server
=
app
.
listen
(
23023
);
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/express/tutorials/specialrouting/package.json
0 → 100644
View file @
9fa45f8
{
"name"
:
"specialrouting"
,
"version"
:
"1.0.0"
,
"description"
:
""
,
"main"
:
"index.js"
,
"scripts"
:
{
"test"
:
"echo
\"
Error: no test specified
\"
&& exit 1"
},
"author"
:
""
,
"license"
:
"ISC"
,
"dependencies"
:
{
"express"
:
"^4.15.2"
}
}
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/express/tutorials/staticfiles/app.js
0 → 100644
View file @
9fa45f8
var
express
=
require
(
'express'
);
var
app
=
express
();
app
.
use
(
express
.
static
(
'public'
));
app
.
get
(
'/'
,
function
(
req
,
res
)
{
res
.
send
(
'Hello World'
);
})
var
server
=
app
.
listen
(
23023
);
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/express/tutorials/staticfiles/package.json
0 → 100644
View file @
9fa45f8
{
"name"
:
"staticfiles"
,
"version"
:
"1.0.0"
,
"description"
:
""
,
"main"
:
"index.js"
,
"scripts"
:
{
"test"
:
"echo
\"
Error: no test specified
\"
&& exit 1"
},
"author"
:
""
,
"license"
:
"ISC"
,
"dependencies"
:
{
"express"
:
"^4.15.2"
}
}
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/express/tutorials/staticfiles/public/icon.png
0 → 100644
View file @
9fa45f8
6.72 KB
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/express/tutorials/staticfiles/public/index.html
0 → 100644
View file @
9fa45f8
<html>
<body>
Public index.html
</body>
</html>
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/messenger/notify/app.js
0 → 100644
View file @
9fa45f8
// 모듈을 읽어 들입니다.
const
request
=
require
(
'request'
);
// 요청을 위한 상수를 선언합니다: TOKEN은 자신의 것을 입력해주세요.
const
TARGET_URL
=
'https://notify-api.line.me/api/notify'
;
const
TOKEN
=
'///채워주세요///'
;
// 요청합니다.
request
.
post
(
{
url
:
TARGET_URL
,
headers
:
{
'Authorization'
:
`Bearer
${
TOKEN
}
`
},
form
:
{
message
:
'안녕하세요. LINE Notify 테스트입니다.'
,
stickerPackageId
:
1
,
stickerId
:
1
}
},(
error
,
response
,
body
)
=>
{
console
.
log
(
body
)
});
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/messenger/notify/package-lock.json
0 → 100644
View file @
9fa45f8
{
"name"
:
"notify"
,
"version"
:
"1.0.0"
,
"lockfileVersion"
:
1
,
"requires"
:
true
,
"dependencies"
:
{
"ajv"
:
{
"version"
:
"6.12.2"
,
"resolved"
:
"https://registry.npmjs.org/ajv/-/ajv-6.12.2.tgz"
,
"integrity"
:
"sha512-k+V+hzjm5q/Mr8ef/1Y9goCmlsK4I6Sm74teeyGvFk1XrOsbsKLjEdrvny42CZ+a8sXbk8KWpY/bDwS+FLL2UQ=="
,
"requires"
:
{
"fast-deep-equal"
:
"^3.1.1"
,
"fast-json-stable-stringify"
:
"^2.0.0"
,
"json-schema-traverse"
:
"^0.4.1"
,
"uri-js"
:
"^4.2.2"
}
},
"asn1"
:
{
"version"
:
"0.2.4"
,
"resolved"
:
"https://registry.npmjs.org/asn1/-/asn1-0.2.4.tgz"
,
"integrity"
:
"sha512-jxwzQpLQjSmWXgwaCZE9Nz+glAG01yF1QnWgbhGwHI5A6FRIEY6IVqtHhIepHqI7/kyEyQEagBC5mBEFlIYvdg=="
,
"requires"
:
{
"safer-buffer"
:
"~2.1.0"
}
},
"assert-plus"
:
{
"version"
:
"1.0.0"
,
"resolved"
:
"https://registry.npmjs.org/assert-plus/-/assert-plus-1.0.0.tgz"
,
"integrity"
:
"sha1-8S4PPF13sLHN2RRpQuTpbB5N1SU="
},
"asynckit"
:
{
"version"
:
"0.4.0"
,
"resolved"
:
"https://registry.npmjs.org/asynckit/-/asynckit-0.4.0.tgz"
,
"integrity"
:
"sha1-x57Zf380y48robyXkLzDZkdLS3k="
},
"aws-sign2"
:
{
"version"
:
"0.7.0"
,
"resolved"
:
"https://registry.npmjs.org/aws-sign2/-/aws-sign2-0.7.0.tgz"
,
"integrity"
:
"sha1-tG6JCTSpWR8tL2+G1+ap8bP+dqg="
},
"aws4"
:
{
"version"
:
"1.9.1"
,
"resolved"
:
"https://registry.npmjs.org/aws4/-/aws4-1.9.1.tgz"
,
"integrity"
:
"sha512-wMHVg2EOHaMRxbzgFJ9gtjOOCrI80OHLG14rxi28XwOW8ux6IiEbRCGGGqCtdAIg4FQCbW20k9RsT4y3gJlFug=="
},
"bcrypt-pbkdf"
:
{
"version"
:
"1.0.2"
,
"resolved"
:
"https://registry.npmjs.org/bcrypt-pbkdf/-/bcrypt-pbkdf-1.0.2.tgz"
,
"integrity"
:
"sha1-pDAdOJtqQ/m2f/PKEaP2Y342Dp4="
,
"requires"
:
{
"tweetnacl"
:
"^0.14.3"
}
},
"caseless"
:
{
"version"
:
"0.12.0"
,
"resolved"
:
"https://registry.npmjs.org/caseless/-/caseless-0.12.0.tgz"
,
"integrity"
:
"sha1-G2gcIf+EAzyCZUMJBolCDRhxUdw="
},
"combined-stream"
:
{
"version"
:
"1.0.8"
,
"resolved"
:
"https://registry.npmjs.org/combined-stream/-/combined-stream-1.0.8.tgz"
,
"integrity"
:
"sha512-FQN4MRfuJeHf7cBbBMJFXhKSDq+2kAArBlmRBvcvFE5BB1HZKXtSFASDhdlz9zOYwxh8lDdnvmMOe/+5cdoEdg=="
,
"requires"
:
{
"delayed-stream"
:
"~1.0.0"
}
},
"core-util-is"
:
{
"version"
:
"1.0.2"
,
"resolved"
:
"https://registry.npmjs.org/core-util-is/-/core-util-is-1.0.2.tgz"
,
"integrity"
:
"sha1-tf1UIgqivFq1eqtxQMlAdUUDwac="
},
"dashdash"
:
{
"version"
:
"1.14.1"
,
"resolved"
:
"https://registry.npmjs.org/dashdash/-/dashdash-1.14.1.tgz"
,
"integrity"
:
"sha1-hTz6D3y+L+1d4gMmuN1YEDX24vA="
,
"requires"
:
{
"assert-plus"
:
"^1.0.0"
}
},
"delayed-stream"
:
{
"version"
:
"1.0.0"
,
"resolved"
:
"https://registry.npmjs.org/delayed-stream/-/delayed-stream-1.0.0.tgz"
,
"integrity"
:
"sha1-3zrhmayt+31ECqrgsp4icrJOxhk="
},
"ecc-jsbn"
:
{
"version"
:
"0.1.2"
,
"resolved"
:
"https://registry.npmjs.org/ecc-jsbn/-/ecc-jsbn-0.1.2.tgz"
,
"integrity"
:
"sha1-OoOpBOVDUyh4dMVkt1SThoSamMk="
,
"requires"
:
{
"jsbn"
:
"~0.1.0"
,
"safer-buffer"
:
"^2.1.0"
}
},
"extend"
:
{
"version"
:
"3.0.2"
,
"resolved"
:
"https://registry.npmjs.org/extend/-/extend-3.0.2.tgz"
,
"integrity"
:
"sha512-fjquC59cD7CyW6urNXK0FBufkZcoiGG80wTuPujX590cB5Ttln20E2UB4S/WARVqhXffZl2LNgS+gQdPIIim/g=="
},
"extsprintf"
:
{
"version"
:
"1.3.0"
,
"resolved"
:
"https://registry.npmjs.org/extsprintf/-/extsprintf-1.3.0.tgz"
,
"integrity"
:
"sha1-lpGEQOMEGnpBT4xS48V06zw+HgU="
},
"fast-deep-equal"
:
{
"version"
:
"3.1.1"
,
"resolved"
:
"https://registry.npmjs.org/fast-deep-equal/-/fast-deep-equal-3.1.1.tgz"
,
"integrity"
:
"sha512-8UEa58QDLauDNfpbrX55Q9jrGHThw2ZMdOky5Gl1CDtVeJDPVrG4Jxx1N8jw2gkWaff5UUuX1KJd+9zGe2B+ZA=="
},
"fast-json-stable-stringify"
:
{
"version"
:
"2.1.0"
,
"resolved"
:
"https://registry.npmjs.org/fast-json-stable-stringify/-/fast-json-stable-stringify-2.1.0.tgz"
,
"integrity"
:
"sha512-lhd/wF+Lk98HZoTCtlVraHtfh5XYijIjalXck7saUtuanSDyLMxnHhSXEDJqHxD7msR8D0uCmqlkwjCV8xvwHw=="
},
"forever-agent"
:
{
"version"
:
"0.6.1"
,
"resolved"
:
"https://registry.npmjs.org/forever-agent/-/forever-agent-0.6.1.tgz"
,
"integrity"
:
"sha1-+8cfDEGt6zf5bFd60e1C2P2sypE="
},
"form-data"
:
{
"version"
:
"2.3.3"
,
"resolved"
:
"https://registry.npmjs.org/form-data/-/form-data-2.3.3.tgz"
,
"integrity"
:
"sha512-1lLKB2Mu3aGP1Q/2eCOx0fNbRMe7XdwktwOruhfqqd0rIJWwN4Dh+E3hrPSlDCXnSR7UtZ1N38rVXm+6+MEhJQ=="
,
"requires"
:
{
"asynckit"
:
"^0.4.0"
,
"combined-stream"
:
"^1.0.6"
,
"mime-types"
:
"^2.1.12"
}
},
"getpass"
:
{
"version"
:
"0.1.7"
,
"resolved"
:
"https://registry.npmjs.org/getpass/-/getpass-0.1.7.tgz"
,
"integrity"
:
"sha1-Xv+OPmhNVprkyysSgmBOi6YhSfo="
,
"requires"
:
{
"assert-plus"
:
"^1.0.0"
}
},
"har-schema"
:
{
"version"
:
"2.0.0"
,
"resolved"
:
"https://registry.npmjs.org/har-schema/-/har-schema-2.0.0.tgz"
,
"integrity"
:
"sha1-qUwiJOvKwEeCoNkDVSHyRzW37JI="
},
"har-validator"
:
{
"version"
:
"5.1.3"
,
"resolved"
:
"https://registry.npmjs.org/har-validator/-/har-validator-5.1.3.tgz"
,
"integrity"
:
"sha512-sNvOCzEQNr/qrvJgc3UG/kD4QtlHycrzwS+6mfTrrSq97BvaYcPZZI1ZSqGSPR73Cxn4LKTD4PttRwfU7jWq5g=="
,
"requires"
:
{
"ajv"
:
"^6.5.5"
,
"har-schema"
:
"^2.0.0"
}
},
"http-signature"
:
{
"version"
:
"1.2.0"
,
"resolved"
:
"https://registry.npmjs.org/http-signature/-/http-signature-1.2.0.tgz"
,
"integrity"
:
"sha1-muzZJRFHcvPZW2WmCruPfBj7rOE="
,
"requires"
:
{
"assert-plus"
:
"^1.0.0"
,
"jsprim"
:
"^1.2.2"
,
"sshpk"
:
"^1.7.0"
}
},
"is-typedarray"
:
{
"version"
:
"1.0.0"
,
"resolved"
:
"https://registry.npmjs.org/is-typedarray/-/is-typedarray-1.0.0.tgz"
,
"integrity"
:
"sha1-5HnICFjfDBsR3dppQPlgEfzaSpo="
},
"isstream"
:
{
"version"
:
"0.1.2"
,
"resolved"
:
"https://registry.npmjs.org/isstream/-/isstream-0.1.2.tgz"
,
"integrity"
:
"sha1-R+Y/evVa+m+S4VAOaQ64uFKcCZo="
},
"jsbn"
:
{
"version"
:
"0.1.1"
,
"resolved"
:
"https://registry.npmjs.org/jsbn/-/jsbn-0.1.1.tgz"
,
"integrity"
:
"sha1-peZUwuWi3rXyAdls77yoDA7y9RM="
},
"json-schema"
:
{
"version"
:
"0.2.3"
,
"resolved"
:
"https://registry.npmjs.org/json-schema/-/json-schema-0.2.3.tgz"
,
"integrity"
:
"sha1-tIDIkuWaLwWVTOcnvT8qTogvnhM="
},
"json-schema-traverse"
:
{
"version"
:
"0.4.1"
,
"resolved"
:
"https://registry.npmjs.org/json-schema-traverse/-/json-schema-traverse-0.4.1.tgz"
,
"integrity"
:
"sha512-xbbCH5dCYU5T8LcEhhuh7HJ88HXuW3qsI3Y0zOZFKfZEHcpWiHU/Jxzk629Brsab/mMiHQti9wMP+845RPe3Vg=="
},
"json-stringify-safe"
:
{
"version"
:
"5.0.1"
,
"resolved"
:
"https://registry.npmjs.org/json-stringify-safe/-/json-stringify-safe-5.0.1.tgz"
,
"integrity"
:
"sha1-Epai1Y/UXxmg9s4B1lcB4sc1tus="
},
"jsprim"
:
{
"version"
:
"1.4.1"
,
"resolved"
:
"https://registry.npmjs.org/jsprim/-/jsprim-1.4.1.tgz"
,
"integrity"
:
"sha1-MT5mvB5cwG5Di8G3SZwuXFastqI="
,
"requires"
:
{
"assert-plus"
:
"1.0.0"
,
"extsprintf"
:
"1.3.0"
,
"json-schema"
:
"0.2.3"
,
"verror"
:
"1.10.0"
}
},
"mime-db"
:
{
"version"
:
"1.44.0"
,
"resolved"
:
"https://registry.npmjs.org/mime-db/-/mime-db-1.44.0.tgz"
,
"integrity"
:
"sha512-/NOTfLrsPBVeH7YtFPgsVWveuL+4SjjYxaQ1xtM1KMFj7HdxlBlxeyNLzhyJVx7r4rZGJAZ/6lkKCitSc/Nmpg=="
},
"mime-types"
:
{
"version"
:
"2.1.27"
,
"resolved"
:
"https://registry.npmjs.org/mime-types/-/mime-types-2.1.27.tgz"
,
"integrity"
:
"sha512-JIhqnCasI9yD+SsmkquHBxTSEuZdQX5BuQnS2Vc7puQQQ+8yiP5AY5uWhpdv4YL4VM5c6iliiYWPgJ/nJQLp7w=="
,
"requires"
:
{
"mime-db"
:
"1.44.0"
}
},
"oauth-sign"
:
{
"version"
:
"0.9.0"
,
"resolved"
:
"https://registry.npmjs.org/oauth-sign/-/oauth-sign-0.9.0.tgz"
,
"integrity"
:
"sha512-fexhUFFPTGV8ybAtSIGbV6gOkSv8UtRbDBnAyLQw4QPKkgNlsH2ByPGtMUqdWkos6YCRmAqViwgZrJc/mRDzZQ=="
},
"performance-now"
:
{
"version"
:
"2.1.0"
,
"resolved"
:
"https://registry.npmjs.org/performance-now/-/performance-now-2.1.0.tgz"
,
"integrity"
:
"sha1-Ywn04OX6kT7BxpMHrjZLSzd8nns="
},
"psl"
:
{
"version"
:
"1.8.0"
,
"resolved"
:
"https://registry.npmjs.org/psl/-/psl-1.8.0.tgz"
,
"integrity"
:
"sha512-RIdOzyoavK+hA18OGGWDqUTsCLhtA7IcZ/6NCs4fFJaHBDab+pDDmDIByWFRQJq2Cd7r1OoQxBGKOaztq+hjIQ=="
},
"punycode"
:
{
"version"
:
"2.1.1"
,
"resolved"
:
"https://registry.npmjs.org/punycode/-/punycode-2.1.1.tgz"
,
"integrity"
:
"sha512-XRsRjdf+j5ml+y/6GKHPZbrF/8p2Yga0JPtdqTIY2Xe5ohJPD9saDJJLPvp9+NSBprVvevdXZybnj2cv8OEd0A=="
},
"qs"
:
{
"version"
:
"6.5.2"
,
"resolved"
:
"https://registry.npmjs.org/qs/-/qs-6.5.2.tgz"
,
"integrity"
:
"sha512-N5ZAX4/LxJmF+7wN74pUD6qAh9/wnvdQcjq9TZjevvXzSUo7bfmw91saqMjzGS2xq91/odN2dW/WOl7qQHNDGA=="
},
"request"
:
{
"version"
:
"2.88.2"
,
"resolved"
:
"https://registry.npmjs.org/request/-/request-2.88.2.tgz"
,
"integrity"
:
"sha512-MsvtOrfG9ZcrOwAW+Qi+F6HbD0CWXEh9ou77uOb7FM2WPhwT7smM833PzanhJLsgXjN89Ir6V2PczXNnMpwKhw=="
,
"requires"
:
{
"aws-sign2"
:
"~0.7.0"
,
"aws4"
:
"^1.8.0"
,
"caseless"
:
"~0.12.0"
,
"combined-stream"
:
"~1.0.6"
,
"extend"
:
"~3.0.2"
,
"forever-agent"
:
"~0.6.1"
,
"form-data"
:
"~2.3.2"
,
"har-validator"
:
"~5.1.3"
,
"http-signature"
:
"~1.2.0"
,
"is-typedarray"
:
"~1.0.0"
,
"isstream"
:
"~0.1.2"
,
"json-stringify-safe"
:
"~5.0.1"
,
"mime-types"
:
"~2.1.19"
,
"oauth-sign"
:
"~0.9.0"
,
"performance-now"
:
"^2.1.0"
,
"qs"
:
"~6.5.2"
,
"safe-buffer"
:
"^5.1.2"
,
"tough-cookie"
:
"~2.5.0"
,
"tunnel-agent"
:
"^0.6.0"
,
"uuid"
:
"^3.3.2"
}
},
"safe-buffer"
:
{
"version"
:
"5.2.1"
,
"resolved"
:
"https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.2.1.tgz"
,
"integrity"
:
"sha512-rp3So07KcdmmKbGvgaNxQSJr7bGVSVk5S9Eq1F+ppbRo70+YeaDxkw5Dd8NPN+GD6bjnYm2VuPuCXmpuYvmCXQ=="
},
"safer-buffer"
:
{
"version"
:
"2.1.2"
,
"resolved"
:
"https://registry.npmjs.org/safer-buffer/-/safer-buffer-2.1.2.tgz"
,
"integrity"
:
"sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg=="
},
"sshpk"
:
{
"version"
:
"1.16.1"
,
"resolved"
:
"https://registry.npmjs.org/sshpk/-/sshpk-1.16.1.tgz"
,
"integrity"
:
"sha512-HXXqVUq7+pcKeLqqZj6mHFUMvXtOJt1uoUx09pFW6011inTMxqI8BA8PM95myrIyyKwdnzjdFjLiE6KBPVtJIg=="
,
"requires"
:
{
"asn1"
:
"~0.2.3"
,
"assert-plus"
:
"^1.0.0"
,
"bcrypt-pbkdf"
:
"^1.0.0"
,
"dashdash"
:
"^1.12.0"
,
"ecc-jsbn"
:
"~0.1.1"
,
"getpass"
:
"^0.1.1"
,
"jsbn"
:
"~0.1.0"
,
"safer-buffer"
:
"^2.0.2"
,
"tweetnacl"
:
"~0.14.0"
}
},
"tough-cookie"
:
{
"version"
:
"2.5.0"
,
"resolved"
:
"https://registry.npmjs.org/tough-cookie/-/tough-cookie-2.5.0.tgz"
,
"integrity"
:
"sha512-nlLsUzgm1kfLXSXfRZMc1KLAugd4hqJHDTvc2hDIwS3mZAfMEuMbc03SujMF+GEcpaX/qboeycw6iO8JwVv2+g=="
,
"requires"
:
{
"psl"
:
"^1.1.28"
,
"punycode"
:
"^2.1.1"
}
},
"tunnel-agent"
:
{
"version"
:
"0.6.0"
,
"resolved"
:
"https://registry.npmjs.org/tunnel-agent/-/tunnel-agent-0.6.0.tgz"
,
"integrity"
:
"sha1-J6XeoGs2sEoKmWZ3SykIaPD8QP0="
,
"requires"
:
{
"safe-buffer"
:
"^5.0.1"
}
},
"tweetnacl"
:
{
"version"
:
"0.14.5"
,
"resolved"
:
"https://registry.npmjs.org/tweetnacl/-/tweetnacl-0.14.5.tgz"
,
"integrity"
:
"sha1-WuaBd/GS1EViadEIr6k/+HQ/T2Q="
},
"uri-js"
:
{
"version"
:
"4.2.2"
,
"resolved"
:
"https://registry.npmjs.org/uri-js/-/uri-js-4.2.2.tgz"
,
"integrity"
:
"sha512-KY9Frmirql91X2Qgjry0Wd4Y+YTdrdZheS8TFwvkbLWf/G5KNJDCh6pKL5OZctEW4+0Baa5idK2ZQuELRwPznQ=="
,
"requires"
:
{
"punycode"
:
"^2.1.0"
}
},
"uuid"
:
{
"version"
:
"3.4.0"
,
"resolved"
:
"https://registry.npmjs.org/uuid/-/uuid-3.4.0.tgz"
,
"integrity"
:
"sha512-HjSDRw6gZE5JMggctHBcjVak08+KEVhSIiDzFnT9S9aegmp85S/bReBVTb4QTFaRNptJ9kuYaNhnbNEOkbKb/A=="
},
"verror"
:
{
"version"
:
"1.10.0"
,
"resolved"
:
"https://registry.npmjs.org/verror/-/verror-1.10.0.tgz"
,
"integrity"
:
"sha1-OhBcoXBTr1XW4nDB+CiGguGNpAA="
,
"requires"
:
{
"assert-plus"
:
"^1.0.0"
,
"core-util-is"
:
"1.0.2"
,
"extsprintf"
:
"^1.2.0"
}
}
}
}
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/messenger/notify/package.json
0 → 100644
View file @
9fa45f8
{
"name"
:
"notify"
,
"version"
:
"1.0.0"
,
"description"
:
""
,
"main"
:
"app.js"
,
"scripts"
:
{
"test"
:
"echo
\"
Error: no test specified
\"
&& exit 1"
},
"author"
:
""
,
"license"
:
"ISC"
,
"dependencies"
:
{
"request"
:
"^2.88.2"
}
}
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/messenger/push/app.js
0 → 100644
View file @
9fa45f8
const
request
=
require
(
'request'
);
const
TARGET_URL
=
'https://api.line.me/v2/bot/message/push'
const
MULTI_TARGET_URL
=
'https://api.line.me/v2/bot/message/multicast'
const
BROAD_TARGET_URL
=
'https://api.line.me/v2/bot/message/broadcast'
const
TOKEN
=
'채널 토큰으로 교체'
const
USER_ID
=
'사용자의 ID, 메세지 수신 시에 확인할 수 있음'
// Single User
// request.post(
// {
// url: TARGET_URL,
// headers: {
// 'Authorization': `Bearer ${TOKEN}`
// },
// json: {
// "to": `${USER_ID}`,
// "messages":[
// {
// "type":"text",
// "text":"Hello, user"
// },
// {
// "type":"text",
// "text":"May I help you?"
// }
// ]
// }
// },(error, response, body) => {
// console.log(body)
// });
// Multicast User
// request.post(
// {
// url: MULTI_TARGET_URL,
// headers: {
// 'Authorization': `Bearer ${TOKEN}`
// },
// json: {
// "to": [`${USER_ID}`],
// "messages":[
// {
// "type":"text",
// "text":"Hello, user"
// },
// {
// "type":"text",
// "text":"May I help you?"
// }
// ]
// }
// },(error, response, body) => {
// console.log(body)
// });
// Broadcast
request
.
post
(
{
url
:
BROAD_TARGET_URL
,
headers
:
{
'Authorization'
:
`Bearer
${
TOKEN
}
`
},
json
:
{
"messages"
:[
{
"type"
:
"text"
,
"text"
:
"Hello, user"
},
{
"type"
:
"text"
,
"text"
:
"May I help you?"
}
]
}
},(
error
,
response
,
body
)
=>
{
console
.
log
(
body
)
});
\ No newline at end of file
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/messenger/push/package-lock.json
0 → 100644
View file @
9fa45f8
{
"name"
:
"push"
,
"version"
:
"1.0.0"
,
"lockfileVersion"
:
1
,
"requires"
:
true
,
"dependencies"
:
{
"ajv"
:
{
"version"
:
"6.12.2"
,
"resolved"
:
"https://registry.npmjs.org/ajv/-/ajv-6.12.2.tgz"
,
"integrity"
:
"sha512-k+V+hzjm5q/Mr8ef/1Y9goCmlsK4I6Sm74teeyGvFk1XrOsbsKLjEdrvny42CZ+a8sXbk8KWpY/bDwS+FLL2UQ=="
,
"requires"
:
{
"fast-deep-equal"
:
"^3.1.1"
,
"fast-json-stable-stringify"
:
"^2.0.0"
,
"json-schema-traverse"
:
"^0.4.1"
,
"uri-js"
:
"^4.2.2"
}
},
"asn1"
:
{
"version"
:
"0.2.4"
,
"resolved"
:
"https://registry.npmjs.org/asn1/-/asn1-0.2.4.tgz"
,
"integrity"
:
"sha512-jxwzQpLQjSmWXgwaCZE9Nz+glAG01yF1QnWgbhGwHI5A6FRIEY6IVqtHhIepHqI7/kyEyQEagBC5mBEFlIYvdg=="
,
"requires"
:
{
"safer-buffer"
:
"~2.1.0"
}
},
"assert-plus"
:
{
"version"
:
"1.0.0"
,
"resolved"
:
"https://registry.npmjs.org/assert-plus/-/assert-plus-1.0.0.tgz"
,
"integrity"
:
"sha1-8S4PPF13sLHN2RRpQuTpbB5N1SU="
},
"asynckit"
:
{
"version"
:
"0.4.0"
,
"resolved"
:
"https://registry.npmjs.org/asynckit/-/asynckit-0.4.0.tgz"
,
"integrity"
:
"sha1-x57Zf380y48robyXkLzDZkdLS3k="
},
"aws-sign2"
:
{
"version"
:
"0.7.0"
,
"resolved"
:
"https://registry.npmjs.org/aws-sign2/-/aws-sign2-0.7.0.tgz"
,
"integrity"
:
"sha1-tG6JCTSpWR8tL2+G1+ap8bP+dqg="
},
"aws4"
:
{
"version"
:
"1.9.1"
,
"resolved"
:
"https://registry.npmjs.org/aws4/-/aws4-1.9.1.tgz"
,
"integrity"
:
"sha512-wMHVg2EOHaMRxbzgFJ9gtjOOCrI80OHLG14rxi28XwOW8ux6IiEbRCGGGqCtdAIg4FQCbW20k9RsT4y3gJlFug=="
},
"bcrypt-pbkdf"
:
{
"version"
:
"1.0.2"
,
"resolved"
:
"https://registry.npmjs.org/bcrypt-pbkdf/-/bcrypt-pbkdf-1.0.2.tgz"
,
"integrity"
:
"sha1-pDAdOJtqQ/m2f/PKEaP2Y342Dp4="
,
"requires"
:
{
"tweetnacl"
:
"^0.14.3"
}
},
"caseless"
:
{
"version"
:
"0.12.0"
,
"resolved"
:
"https://registry.npmjs.org/caseless/-/caseless-0.12.0.tgz"
,
"integrity"
:
"sha1-G2gcIf+EAzyCZUMJBolCDRhxUdw="
},
"combined-stream"
:
{
"version"
:
"1.0.8"
,
"resolved"
:
"https://registry.npmjs.org/combined-stream/-/combined-stream-1.0.8.tgz"
,
"integrity"
:
"sha512-FQN4MRfuJeHf7cBbBMJFXhKSDq+2kAArBlmRBvcvFE5BB1HZKXtSFASDhdlz9zOYwxh8lDdnvmMOe/+5cdoEdg=="
,
"requires"
:
{
"delayed-stream"
:
"~1.0.0"
}
},
"core-util-is"
:
{
"version"
:
"1.0.2"
,
"resolved"
:
"https://registry.npmjs.org/core-util-is/-/core-util-is-1.0.2.tgz"
,
"integrity"
:
"sha1-tf1UIgqivFq1eqtxQMlAdUUDwac="
},
"dashdash"
:
{
"version"
:
"1.14.1"
,
"resolved"
:
"https://registry.npmjs.org/dashdash/-/dashdash-1.14.1.tgz"
,
"integrity"
:
"sha1-hTz6D3y+L+1d4gMmuN1YEDX24vA="
,
"requires"
:
{
"assert-plus"
:
"^1.0.0"
}
},
"delayed-stream"
:
{
"version"
:
"1.0.0"
,
"resolved"
:
"https://registry.npmjs.org/delayed-stream/-/delayed-stream-1.0.0.tgz"
,
"integrity"
:
"sha1-3zrhmayt+31ECqrgsp4icrJOxhk="
},
"ecc-jsbn"
:
{
"version"
:
"0.1.2"
,
"resolved"
:
"https://registry.npmjs.org/ecc-jsbn/-/ecc-jsbn-0.1.2.tgz"
,
"integrity"
:
"sha1-OoOpBOVDUyh4dMVkt1SThoSamMk="
,
"requires"
:
{
"jsbn"
:
"~0.1.0"
,
"safer-buffer"
:
"^2.1.0"
}
},
"extend"
:
{
"version"
:
"3.0.2"
,
"resolved"
:
"https://registry.npmjs.org/extend/-/extend-3.0.2.tgz"
,
"integrity"
:
"sha512-fjquC59cD7CyW6urNXK0FBufkZcoiGG80wTuPujX590cB5Ttln20E2UB4S/WARVqhXffZl2LNgS+gQdPIIim/g=="
},
"extsprintf"
:
{
"version"
:
"1.3.0"
,
"resolved"
:
"https://registry.npmjs.org/extsprintf/-/extsprintf-1.3.0.tgz"
,
"integrity"
:
"sha1-lpGEQOMEGnpBT4xS48V06zw+HgU="
},
"fast-deep-equal"
:
{
"version"
:
"3.1.1"
,
"resolved"
:
"https://registry.npmjs.org/fast-deep-equal/-/fast-deep-equal-3.1.1.tgz"
,
"integrity"
:
"sha512-8UEa58QDLauDNfpbrX55Q9jrGHThw2ZMdOky5Gl1CDtVeJDPVrG4Jxx1N8jw2gkWaff5UUuX1KJd+9zGe2B+ZA=="
},
"fast-json-stable-stringify"
:
{
"version"
:
"2.1.0"
,
"resolved"
:
"https://registry.npmjs.org/fast-json-stable-stringify/-/fast-json-stable-stringify-2.1.0.tgz"
,
"integrity"
:
"sha512-lhd/wF+Lk98HZoTCtlVraHtfh5XYijIjalXck7saUtuanSDyLMxnHhSXEDJqHxD7msR8D0uCmqlkwjCV8xvwHw=="
},
"forever-agent"
:
{
"version"
:
"0.6.1"
,
"resolved"
:
"https://registry.npmjs.org/forever-agent/-/forever-agent-0.6.1.tgz"
,
"integrity"
:
"sha1-+8cfDEGt6zf5bFd60e1C2P2sypE="
},
"form-data"
:
{
"version"
:
"2.3.3"
,
"resolved"
:
"https://registry.npmjs.org/form-data/-/form-data-2.3.3.tgz"
,
"integrity"
:
"sha512-1lLKB2Mu3aGP1Q/2eCOx0fNbRMe7XdwktwOruhfqqd0rIJWwN4Dh+E3hrPSlDCXnSR7UtZ1N38rVXm+6+MEhJQ=="
,
"requires"
:
{
"asynckit"
:
"^0.4.0"
,
"combined-stream"
:
"^1.0.6"
,
"mime-types"
:
"^2.1.12"
}
},
"getpass"
:
{
"version"
:
"0.1.7"
,
"resolved"
:
"https://registry.npmjs.org/getpass/-/getpass-0.1.7.tgz"
,
"integrity"
:
"sha1-Xv+OPmhNVprkyysSgmBOi6YhSfo="
,
"requires"
:
{
"assert-plus"
:
"^1.0.0"
}
},
"har-schema"
:
{
"version"
:
"2.0.0"
,
"resolved"
:
"https://registry.npmjs.org/har-schema/-/har-schema-2.0.0.tgz"
,
"integrity"
:
"sha1-qUwiJOvKwEeCoNkDVSHyRzW37JI="
},
"har-validator"
:
{
"version"
:
"5.1.3"
,
"resolved"
:
"https://registry.npmjs.org/har-validator/-/har-validator-5.1.3.tgz"
,
"integrity"
:
"sha512-sNvOCzEQNr/qrvJgc3UG/kD4QtlHycrzwS+6mfTrrSq97BvaYcPZZI1ZSqGSPR73Cxn4LKTD4PttRwfU7jWq5g=="
,
"requires"
:
{
"ajv"
:
"^6.5.5"
,
"har-schema"
:
"^2.0.0"
}
},
"http-signature"
:
{
"version"
:
"1.2.0"
,
"resolved"
:
"https://registry.npmjs.org/http-signature/-/http-signature-1.2.0.tgz"
,
"integrity"
:
"sha1-muzZJRFHcvPZW2WmCruPfBj7rOE="
,
"requires"
:
{
"assert-plus"
:
"^1.0.0"
,
"jsprim"
:
"^1.2.2"
,
"sshpk"
:
"^1.7.0"
}
},
"is-typedarray"
:
{
"version"
:
"1.0.0"
,
"resolved"
:
"https://registry.npmjs.org/is-typedarray/-/is-typedarray-1.0.0.tgz"
,
"integrity"
:
"sha1-5HnICFjfDBsR3dppQPlgEfzaSpo="
},
"isstream"
:
{
"version"
:
"0.1.2"
,
"resolved"
:
"https://registry.npmjs.org/isstream/-/isstream-0.1.2.tgz"
,
"integrity"
:
"sha1-R+Y/evVa+m+S4VAOaQ64uFKcCZo="
},
"jsbn"
:
{
"version"
:
"0.1.1"
,
"resolved"
:
"https://registry.npmjs.org/jsbn/-/jsbn-0.1.1.tgz"
,
"integrity"
:
"sha1-peZUwuWi3rXyAdls77yoDA7y9RM="
},
"json-schema"
:
{
"version"
:
"0.2.3"
,
"resolved"
:
"https://registry.npmjs.org/json-schema/-/json-schema-0.2.3.tgz"
,
"integrity"
:
"sha1-tIDIkuWaLwWVTOcnvT8qTogvnhM="
},
"json-schema-traverse"
:
{
"version"
:
"0.4.1"
,
"resolved"
:
"https://registry.npmjs.org/json-schema-traverse/-/json-schema-traverse-0.4.1.tgz"
,
"integrity"
:
"sha512-xbbCH5dCYU5T8LcEhhuh7HJ88HXuW3qsI3Y0zOZFKfZEHcpWiHU/Jxzk629Brsab/mMiHQti9wMP+845RPe3Vg=="
},
"json-stringify-safe"
:
{
"version"
:
"5.0.1"
,
"resolved"
:
"https://registry.npmjs.org/json-stringify-safe/-/json-stringify-safe-5.0.1.tgz"
,
"integrity"
:
"sha1-Epai1Y/UXxmg9s4B1lcB4sc1tus="
},
"jsprim"
:
{
"version"
:
"1.4.1"
,
"resolved"
:
"https://registry.npmjs.org/jsprim/-/jsprim-1.4.1.tgz"
,
"integrity"
:
"sha1-MT5mvB5cwG5Di8G3SZwuXFastqI="
,
"requires"
:
{
"assert-plus"
:
"1.0.0"
,
"extsprintf"
:
"1.3.0"
,
"json-schema"
:
"0.2.3"
,
"verror"
:
"1.10.0"
}
},
"mime-db"
:
{
"version"
:
"1.44.0"
,
"resolved"
:
"https://registry.npmjs.org/mime-db/-/mime-db-1.44.0.tgz"
,
"integrity"
:
"sha512-/NOTfLrsPBVeH7YtFPgsVWveuL+4SjjYxaQ1xtM1KMFj7HdxlBlxeyNLzhyJVx7r4rZGJAZ/6lkKCitSc/Nmpg=="
},
"mime-types"
:
{
"version"
:
"2.1.27"
,
"resolved"
:
"https://registry.npmjs.org/mime-types/-/mime-types-2.1.27.tgz"
,
"integrity"
:
"sha512-JIhqnCasI9yD+SsmkquHBxTSEuZdQX5BuQnS2Vc7puQQQ+8yiP5AY5uWhpdv4YL4VM5c6iliiYWPgJ/nJQLp7w=="
,
"requires"
:
{
"mime-db"
:
"1.44.0"
}
},
"oauth-sign"
:
{
"version"
:
"0.9.0"
,
"resolved"
:
"https://registry.npmjs.org/oauth-sign/-/oauth-sign-0.9.0.tgz"
,
"integrity"
:
"sha512-fexhUFFPTGV8ybAtSIGbV6gOkSv8UtRbDBnAyLQw4QPKkgNlsH2ByPGtMUqdWkos6YCRmAqViwgZrJc/mRDzZQ=="
},
"performance-now"
:
{
"version"
:
"2.1.0"
,
"resolved"
:
"https://registry.npmjs.org/performance-now/-/performance-now-2.1.0.tgz"
,
"integrity"
:
"sha1-Ywn04OX6kT7BxpMHrjZLSzd8nns="
},
"psl"
:
{
"version"
:
"1.8.0"
,
"resolved"
:
"https://registry.npmjs.org/psl/-/psl-1.8.0.tgz"
,
"integrity"
:
"sha512-RIdOzyoavK+hA18OGGWDqUTsCLhtA7IcZ/6NCs4fFJaHBDab+pDDmDIByWFRQJq2Cd7r1OoQxBGKOaztq+hjIQ=="
},
"punycode"
:
{
"version"
:
"2.1.1"
,
"resolved"
:
"https://registry.npmjs.org/punycode/-/punycode-2.1.1.tgz"
,
"integrity"
:
"sha512-XRsRjdf+j5ml+y/6GKHPZbrF/8p2Yga0JPtdqTIY2Xe5ohJPD9saDJJLPvp9+NSBprVvevdXZybnj2cv8OEd0A=="
},
"qs"
:
{
"version"
:
"6.5.2"
,
"resolved"
:
"https://registry.npmjs.org/qs/-/qs-6.5.2.tgz"
,
"integrity"
:
"sha512-N5ZAX4/LxJmF+7wN74pUD6qAh9/wnvdQcjq9TZjevvXzSUo7bfmw91saqMjzGS2xq91/odN2dW/WOl7qQHNDGA=="
},
"request"
:
{
"version"
:
"2.88.2"
,
"resolved"
:
"https://registry.npmjs.org/request/-/request-2.88.2.tgz"
,
"integrity"
:
"sha512-MsvtOrfG9ZcrOwAW+Qi+F6HbD0CWXEh9ou77uOb7FM2WPhwT7smM833PzanhJLsgXjN89Ir6V2PczXNnMpwKhw=="
,
"requires"
:
{
"aws-sign2"
:
"~0.7.0"
,
"aws4"
:
"^1.8.0"
,
"caseless"
:
"~0.12.0"
,
"combined-stream"
:
"~1.0.6"
,
"extend"
:
"~3.0.2"
,
"forever-agent"
:
"~0.6.1"
,
"form-data"
:
"~2.3.2"
,
"har-validator"
:
"~5.1.3"
,
"http-signature"
:
"~1.2.0"
,
"is-typedarray"
:
"~1.0.0"
,
"isstream"
:
"~0.1.2"
,
"json-stringify-safe"
:
"~5.0.1"
,
"mime-types"
:
"~2.1.19"
,
"oauth-sign"
:
"~0.9.0"
,
"performance-now"
:
"^2.1.0"
,
"qs"
:
"~6.5.2"
,
"safe-buffer"
:
"^5.1.2"
,
"tough-cookie"
:
"~2.5.0"
,
"tunnel-agent"
:
"^0.6.0"
,
"uuid"
:
"^3.3.2"
}
},
"safe-buffer"
:
{
"version"
:
"5.2.1"
,
"resolved"
:
"https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.2.1.tgz"
,
"integrity"
:
"sha512-rp3So07KcdmmKbGvgaNxQSJr7bGVSVk5S9Eq1F+ppbRo70+YeaDxkw5Dd8NPN+GD6bjnYm2VuPuCXmpuYvmCXQ=="
},
"safer-buffer"
:
{
"version"
:
"2.1.2"
,
"resolved"
:
"https://registry.npmjs.org/safer-buffer/-/safer-buffer-2.1.2.tgz"
,
"integrity"
:
"sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg=="
},
"sshpk"
:
{
"version"
:
"1.16.1"
,
"resolved"
:
"https://registry.npmjs.org/sshpk/-/sshpk-1.16.1.tgz"
,
"integrity"
:
"sha512-HXXqVUq7+pcKeLqqZj6mHFUMvXtOJt1uoUx09pFW6011inTMxqI8BA8PM95myrIyyKwdnzjdFjLiE6KBPVtJIg=="
,
"requires"
:
{
"asn1"
:
"~0.2.3"
,
"assert-plus"
:
"^1.0.0"
,
"bcrypt-pbkdf"
:
"^1.0.0"
,
"dashdash"
:
"^1.12.0"
,
"ecc-jsbn"
:
"~0.1.1"
,
"getpass"
:
"^0.1.1"
,
"jsbn"
:
"~0.1.0"
,
"safer-buffer"
:
"^2.0.2"
,
"tweetnacl"
:
"~0.14.0"
}
},
"tough-cookie"
:
{
"version"
:
"2.5.0"
,
"resolved"
:
"https://registry.npmjs.org/tough-cookie/-/tough-cookie-2.5.0.tgz"
,
"integrity"
:
"sha512-nlLsUzgm1kfLXSXfRZMc1KLAugd4hqJHDTvc2hDIwS3mZAfMEuMbc03SujMF+GEcpaX/qboeycw6iO8JwVv2+g=="
,
"requires"
:
{
"psl"
:
"^1.1.28"
,
"punycode"
:
"^2.1.1"
}
},
"tunnel-agent"
:
{
"version"
:
"0.6.0"
,
"resolved"
:
"https://registry.npmjs.org/tunnel-agent/-/tunnel-agent-0.6.0.tgz"
,
"integrity"
:
"sha1-J6XeoGs2sEoKmWZ3SykIaPD8QP0="
,
"requires"
:
{
"safe-buffer"
:
"^5.0.1"
}
},
"tweetnacl"
:
{
"version"
:
"0.14.5"
,
"resolved"
:
"https://registry.npmjs.org/tweetnacl/-/tweetnacl-0.14.5.tgz"
,
"integrity"
:
"sha1-WuaBd/GS1EViadEIr6k/+HQ/T2Q="
},
"uri-js"
:
{
"version"
:
"4.2.2"
,
"resolved"
:
"https://registry.npmjs.org/uri-js/-/uri-js-4.2.2.tgz"
,
"integrity"
:
"sha512-KY9Frmirql91X2Qgjry0Wd4Y+YTdrdZheS8TFwvkbLWf/G5KNJDCh6pKL5OZctEW4+0Baa5idK2ZQuELRwPznQ=="
,
"requires"
:
{
"punycode"
:
"^2.1.0"
}
},
"uuid"
:
{
"version"
:
"3.4.0"
,
"resolved"
:
"https://registry.npmjs.org/uuid/-/uuid-3.4.0.tgz"
,
"integrity"
:
"sha512-HjSDRw6gZE5JMggctHBcjVak08+KEVhSIiDzFnT9S9aegmp85S/bReBVTb4QTFaRNptJ9kuYaNhnbNEOkbKb/A=="
},
"verror"
:
{
"version"
:
"1.10.0"
,
"resolved"
:
"https://registry.npmjs.org/verror/-/verror-1.10.0.tgz"
,
"integrity"
:
"sha1-OhBcoXBTr1XW4nDB+CiGguGNpAA="
,
"requires"
:
{
"assert-plus"
:
"^1.0.0"
,
"core-util-is"
:
"1.0.2"
,
"extsprintf"
:
"^1.2.0"
}
}
}
}
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/messenger/push/package.json
0 → 100644
View file @
9fa45f8
{
"name"
:
"push"
,
"version"
:
"1.0.0"
,
"description"
:
""
,
"main"
:
"app.js"
,
"scripts"
:
{
"test"
:
"echo
\"
Error: no test specified
\"
&& exit 1"
},
"author"
:
""
,
"license"
:
"ISC"
,
"dependencies"
:
{
"request"
:
"^2.88.2"
}
}
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/messenger/reply/app.js
0 → 100644
View file @
9fa45f8
var
express
=
require
(
'express'
);
const
request
=
require
(
'request'
);
const
TARGET_URL
=
'https://api.line.me/v2/bot/message/reply'
const
TOKEN
=
'채널 토큰으로 변경'
const
fs
=
require
(
'fs'
);
const
path
=
require
(
'path'
);
const
HTTPS
=
require
(
'https'
);
const
domain
=
"도메인 변경"
const
sslport
=
23023
;
const
bodyParser
=
require
(
'body-parser'
);
var
app
=
express
();
app
.
use
(
bodyParser
.
json
());
app
.
post
(
'/hook'
,
function
(
req
,
res
)
{
var
eventObj
=
req
.
body
.
events
[
0
];
var
source
=
eventObj
.
source
;
var
message
=
eventObj
.
message
;
// request log
console
.
log
(
'======================'
,
new
Date
()
,
'======================'
);
console
.
log
(
'[request]'
,
req
.
body
);
console
.
log
(
'[request source] '
,
eventObj
.
source
);
console
.
log
(
'[request message]'
,
eventObj
.
message
);
request
.
post
(
{
url
:
TARGET_URL
,
headers
:
{
'Authorization'
:
`Bearer
${
TOKEN
}
`
},
json
:
{
"replyToken"
:
eventObj
.
replyToken
,
"messages"
:[
{
"type"
:
"text"
,
"text"
:
"Hello, user"
},
{
"type"
:
"text"
,
"text"
:
"May I help you?"
}
]
}
},(
error
,
response
,
body
)
=>
{
console
.
log
(
body
)
});
res
.
sendStatus
(
200
);
});
try
{
const
option
=
{
ca
:
fs
.
readFileSync
(
'/etc/letsencrypt/live/'
+
domain
+
'/fullchain.pem'
),
key
:
fs
.
readFileSync
(
path
.
resolve
(
process
.
cwd
(),
'/etc/letsencrypt/live/'
+
domain
+
'/privkey.pem'
),
'utf8'
).
toString
(),
cert
:
fs
.
readFileSync
(
path
.
resolve
(
process
.
cwd
(),
'/etc/letsencrypt/live/'
+
domain
+
'/cert.pem'
),
'utf8'
).
toString
(),
};
HTTPS
.
createServer
(
option
,
app
).
listen
(
sslport
,
()
=>
{
console
.
log
(
`[HTTPS] Server is started on port
${
sslport
}
`
);
});
}
catch
(
error
)
{
console
.
log
(
'[HTTPS] HTTPS 오류가 발생하였습니다. HTTPS 서버는 실행되지 않습니다.'
);
console
.
log
(
error
);
}
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/messenger/reply/package-lock.json
0 → 100644
View file @
9fa45f8
{
"name"
:
"reply"
,
"version"
:
"1.0.0"
,
"lockfileVersion"
:
1
,
"requires"
:
true
,
"dependencies"
:
{
"accepts"
:
{
"version"
:
"1.3.7"
,
"resolved"
:
"https://registry.npmjs.org/accepts/-/accepts-1.3.7.tgz"
,
"integrity"
:
"sha512-Il80Qs2WjYlJIBNzNkK6KYqlVMTbZLXgHx2oT0pU/fjRHyEp+PEfEPY0R3WCwAGVOtauxh1hOxNgIf5bv7dQpA=="
,
"requires"
:
{
"mime-types"
:
"~2.1.24"
,
"negotiator"
:
"0.6.2"
}
},
"ajv"
:
{
"version"
:
"6.12.2"
,
"resolved"
:
"https://registry.npmjs.org/ajv/-/ajv-6.12.2.tgz"
,
"integrity"
:
"sha512-k+V+hzjm5q/Mr8ef/1Y9goCmlsK4I6Sm74teeyGvFk1XrOsbsKLjEdrvny42CZ+a8sXbk8KWpY/bDwS+FLL2UQ=="
,
"requires"
:
{
"fast-deep-equal"
:
"^3.1.1"
,
"fast-json-stable-stringify"
:
"^2.0.0"
,
"json-schema-traverse"
:
"^0.4.1"
,
"uri-js"
:
"^4.2.2"
}
},
"array-flatten"
:
{
"version"
:
"1.1.1"
,
"resolved"
:
"https://registry.npmjs.org/array-flatten/-/array-flatten-1.1.1.tgz"
,
"integrity"
:
"sha1-ml9pkFGx5wczKPKgCJaLZOopVdI="
},
"asn1"
:
{
"version"
:
"0.2.4"
,
"resolved"
:
"https://registry.npmjs.org/asn1/-/asn1-0.2.4.tgz"
,
"integrity"
:
"sha512-jxwzQpLQjSmWXgwaCZE9Nz+glAG01yF1QnWgbhGwHI5A6FRIEY6IVqtHhIepHqI7/kyEyQEagBC5mBEFlIYvdg=="
,
"requires"
:
{
"safer-buffer"
:
"~2.1.0"
}
},
"assert-plus"
:
{
"version"
:
"1.0.0"
,
"resolved"
:
"https://registry.npmjs.org/assert-plus/-/assert-plus-1.0.0.tgz"
,
"integrity"
:
"sha1-8S4PPF13sLHN2RRpQuTpbB5N1SU="
},
"asynckit"
:
{
"version"
:
"0.4.0"
,
"resolved"
:
"https://registry.npmjs.org/asynckit/-/asynckit-0.4.0.tgz"
,
"integrity"
:
"sha1-x57Zf380y48robyXkLzDZkdLS3k="
},
"aws-sign2"
:
{
"version"
:
"0.7.0"
,
"resolved"
:
"https://registry.npmjs.org/aws-sign2/-/aws-sign2-0.7.0.tgz"
,
"integrity"
:
"sha1-tG6JCTSpWR8tL2+G1+ap8bP+dqg="
},
"aws4"
:
{
"version"
:
"1.9.1"
,
"resolved"
:
"https://registry.npmjs.org/aws4/-/aws4-1.9.1.tgz"
,
"integrity"
:
"sha512-wMHVg2EOHaMRxbzgFJ9gtjOOCrI80OHLG14rxi28XwOW8ux6IiEbRCGGGqCtdAIg4FQCbW20k9RsT4y3gJlFug=="
},
"bcrypt-pbkdf"
:
{
"version"
:
"1.0.2"
,
"resolved"
:
"https://registry.npmjs.org/bcrypt-pbkdf/-/bcrypt-pbkdf-1.0.2.tgz"
,
"integrity"
:
"sha1-pDAdOJtqQ/m2f/PKEaP2Y342Dp4="
,
"requires"
:
{
"tweetnacl"
:
"^0.14.3"
}
},
"body-parser"
:
{
"version"
:
"1.19.0"
,
"resolved"
:
"https://registry.npmjs.org/body-parser/-/body-parser-1.19.0.tgz"
,
"integrity"
:
"sha512-dhEPs72UPbDnAQJ9ZKMNTP6ptJaionhP5cBb541nXPlW60Jepo9RV/a4fX4XWW9CuFNK22krhrj1+rgzifNCsw=="
,
"requires"
:
{
"bytes"
:
"3.1.0"
,
"content-type"
:
"~1.0.4"
,
"debug"
:
"2.6.9"
,
"depd"
:
"~1.1.2"
,
"http-errors"
:
"1.7.2"
,
"iconv-lite"
:
"0.4.24"
,
"on-finished"
:
"~2.3.0"
,
"qs"
:
"6.7.0"
,
"raw-body"
:
"2.4.0"
,
"type-is"
:
"~1.6.17"
}
},
"bytes"
:
{
"version"
:
"3.1.0"
,
"resolved"
:
"https://registry.npmjs.org/bytes/-/bytes-3.1.0.tgz"
,
"integrity"
:
"sha512-zauLjrfCG+xvoyaqLoV8bLVXXNGC4JqlxFCutSDWA6fJrTo2ZuvLYTqZ7aHBLZSMOopbzwv8f+wZcVzfVTI2Dg=="
},
"caseless"
:
{
"version"
:
"0.12.0"
,
"resolved"
:
"https://registry.npmjs.org/caseless/-/caseless-0.12.0.tgz"
,
"integrity"
:
"sha1-G2gcIf+EAzyCZUMJBolCDRhxUdw="
},
"combined-stream"
:
{
"version"
:
"1.0.8"
,
"resolved"
:
"https://registry.npmjs.org/combined-stream/-/combined-stream-1.0.8.tgz"
,
"integrity"
:
"sha512-FQN4MRfuJeHf7cBbBMJFXhKSDq+2kAArBlmRBvcvFE5BB1HZKXtSFASDhdlz9zOYwxh8lDdnvmMOe/+5cdoEdg=="
,
"requires"
:
{
"delayed-stream"
:
"~1.0.0"
}
},
"content-disposition"
:
{
"version"
:
"0.5.3"
,
"resolved"
:
"https://registry.npmjs.org/content-disposition/-/content-disposition-0.5.3.tgz"
,
"integrity"
:
"sha512-ExO0774ikEObIAEV9kDo50o+79VCUdEB6n6lzKgGwupcVeRlhrj3qGAfwq8G6uBJjkqLrhT0qEYFcWng8z1z0g=="
,
"requires"
:
{
"safe-buffer"
:
"5.1.2"
}
},
"content-type"
:
{
"version"
:
"1.0.4"
,
"resolved"
:
"https://registry.npmjs.org/content-type/-/content-type-1.0.4.tgz"
,
"integrity"
:
"sha512-hIP3EEPs8tB9AT1L+NUqtwOAps4mk2Zob89MWXMHjHWg9milF/j4osnnQLXBCBFBk/tvIG/tUc9mOUJiPBhPXA=="
},
"cookie"
:
{
"version"
:
"0.4.0"
,
"resolved"
:
"https://registry.npmjs.org/cookie/-/cookie-0.4.0.tgz"
,
"integrity"
:
"sha512-+Hp8fLp57wnUSt0tY0tHEXh4voZRDnoIrZPqlo3DPiI4y9lwg/jqx+1Om94/W6ZaPDOUbnjOt/99w66zk+l1Xg=="
},
"cookie-signature"
:
{
"version"
:
"1.0.6"
,
"resolved"
:
"https://registry.npmjs.org/cookie-signature/-/cookie-signature-1.0.6.tgz"
,
"integrity"
:
"sha1-4wOogrNCzD7oylE6eZmXNNqzriw="
},
"core-util-is"
:
{
"version"
:
"1.0.2"
,
"resolved"
:
"https://registry.npmjs.org/core-util-is/-/core-util-is-1.0.2.tgz"
,
"integrity"
:
"sha1-tf1UIgqivFq1eqtxQMlAdUUDwac="
},
"dashdash"
:
{
"version"
:
"1.14.1"
,
"resolved"
:
"https://registry.npmjs.org/dashdash/-/dashdash-1.14.1.tgz"
,
"integrity"
:
"sha1-hTz6D3y+L+1d4gMmuN1YEDX24vA="
,
"requires"
:
{
"assert-plus"
:
"^1.0.0"
}
},
"debug"
:
{
"version"
:
"2.6.9"
,
"resolved"
:
"https://registry.npmjs.org/debug/-/debug-2.6.9.tgz"
,
"integrity"
:
"sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA=="
,
"requires"
:
{
"ms"
:
"2.0.0"
}
},
"delayed-stream"
:
{
"version"
:
"1.0.0"
,
"resolved"
:
"https://registry.npmjs.org/delayed-stream/-/delayed-stream-1.0.0.tgz"
,
"integrity"
:
"sha1-3zrhmayt+31ECqrgsp4icrJOxhk="
},
"depd"
:
{
"version"
:
"1.1.2"
,
"resolved"
:
"https://registry.npmjs.org/depd/-/depd-1.1.2.tgz"
,
"integrity"
:
"sha1-m81S4UwJd2PnSbJ0xDRu0uVgtak="
},
"destroy"
:
{
"version"
:
"1.0.4"
,
"resolved"
:
"https://registry.npmjs.org/destroy/-/destroy-1.0.4.tgz"
,
"integrity"
:
"sha1-l4hXRCxEdJ5CBmE+N5RiBYJqvYA="
},
"ecc-jsbn"
:
{
"version"
:
"0.1.2"
,
"resolved"
:
"https://registry.npmjs.org/ecc-jsbn/-/ecc-jsbn-0.1.2.tgz"
,
"integrity"
:
"sha1-OoOpBOVDUyh4dMVkt1SThoSamMk="
,
"requires"
:
{
"jsbn"
:
"~0.1.0"
,
"safer-buffer"
:
"^2.1.0"
}
},
"ee-first"
:
{
"version"
:
"1.1.1"
,
"resolved"
:
"https://registry.npmjs.org/ee-first/-/ee-first-1.1.1.tgz"
,
"integrity"
:
"sha1-WQxhFWsK4vTwJVcyoViyZrxWsh0="
},
"encodeurl"
:
{
"version"
:
"1.0.2"
,
"resolved"
:
"https://registry.npmjs.org/encodeurl/-/encodeurl-1.0.2.tgz"
,
"integrity"
:
"sha1-rT/0yG7C0CkyL1oCw6mmBslbP1k="
},
"escape-html"
:
{
"version"
:
"1.0.3"
,
"resolved"
:
"https://registry.npmjs.org/escape-html/-/escape-html-1.0.3.tgz"
,
"integrity"
:
"sha1-Aljq5NPQwJdN4cFpGI7wBR0dGYg="
},
"etag"
:
{
"version"
:
"1.8.1"
,
"resolved"
:
"https://registry.npmjs.org/etag/-/etag-1.8.1.tgz"
,
"integrity"
:
"sha1-Qa4u62XvpiJorr/qg6x9eSmbCIc="
},
"express"
:
{
"version"
:
"4.17.1"
,
"resolved"
:
"https://registry.npmjs.org/express/-/express-4.17.1.tgz"
,
"integrity"
:
"sha512-mHJ9O79RqluphRrcw2X/GTh3k9tVv8YcoyY4Kkh4WDMUYKRZUq0h1o0w2rrrxBqM7VoeUVqgb27xlEMXTnYt4g=="
,
"requires"
:
{
"accepts"
:
"~1.3.7"
,
"array-flatten"
:
"1.1.1"
,
"body-parser"
:
"1.19.0"
,
"content-disposition"
:
"0.5.3"
,
"content-type"
:
"~1.0.4"
,
"cookie"
:
"0.4.0"
,
"cookie-signature"
:
"1.0.6"
,
"debug"
:
"2.6.9"
,
"depd"
:
"~1.1.2"
,
"encodeurl"
:
"~1.0.2"
,
"escape-html"
:
"~1.0.3"
,
"etag"
:
"~1.8.1"
,
"finalhandler"
:
"~1.1.2"
,
"fresh"
:
"0.5.2"
,
"merge-descriptors"
:
"1.0.1"
,
"methods"
:
"~1.1.2"
,
"on-finished"
:
"~2.3.0"
,
"parseurl"
:
"~1.3.3"
,
"path-to-regexp"
:
"0.1.7"
,
"proxy-addr"
:
"~2.0.5"
,
"qs"
:
"6.7.0"
,
"range-parser"
:
"~1.2.1"
,
"safe-buffer"
:
"5.1.2"
,
"send"
:
"0.17.1"
,
"serve-static"
:
"1.14.1"
,
"setprototypeof"
:
"1.1.1"
,
"statuses"
:
"~1.5.0"
,
"type-is"
:
"~1.6.18"
,
"utils-merge"
:
"1.0.1"
,
"vary"
:
"~1.1.2"
}
},
"extend"
:
{
"version"
:
"3.0.2"
,
"resolved"
:
"https://registry.npmjs.org/extend/-/extend-3.0.2.tgz"
,
"integrity"
:
"sha512-fjquC59cD7CyW6urNXK0FBufkZcoiGG80wTuPujX590cB5Ttln20E2UB4S/WARVqhXffZl2LNgS+gQdPIIim/g=="
},
"extsprintf"
:
{
"version"
:
"1.3.0"
,
"resolved"
:
"https://registry.npmjs.org/extsprintf/-/extsprintf-1.3.0.tgz"
,
"integrity"
:
"sha1-lpGEQOMEGnpBT4xS48V06zw+HgU="
},
"fast-deep-equal"
:
{
"version"
:
"3.1.1"
,
"resolved"
:
"https://registry.npmjs.org/fast-deep-equal/-/fast-deep-equal-3.1.1.tgz"
,
"integrity"
:
"sha512-8UEa58QDLauDNfpbrX55Q9jrGHThw2ZMdOky5Gl1CDtVeJDPVrG4Jxx1N8jw2gkWaff5UUuX1KJd+9zGe2B+ZA=="
},
"fast-json-stable-stringify"
:
{
"version"
:
"2.1.0"
,
"resolved"
:
"https://registry.npmjs.org/fast-json-stable-stringify/-/fast-json-stable-stringify-2.1.0.tgz"
,
"integrity"
:
"sha512-lhd/wF+Lk98HZoTCtlVraHtfh5XYijIjalXck7saUtuanSDyLMxnHhSXEDJqHxD7msR8D0uCmqlkwjCV8xvwHw=="
},
"finalhandler"
:
{
"version"
:
"1.1.2"
,
"resolved"
:
"https://registry.npmjs.org/finalhandler/-/finalhandler-1.1.2.tgz"
,
"integrity"
:
"sha512-aAWcW57uxVNrQZqFXjITpW3sIUQmHGG3qSb9mUah9MgMC4NeWhNOlNjXEYq3HjRAvL6arUviZGGJsBg6z0zsWA=="
,
"requires"
:
{
"debug"
:
"2.6.9"
,
"encodeurl"
:
"~1.0.2"
,
"escape-html"
:
"~1.0.3"
,
"on-finished"
:
"~2.3.0"
,
"parseurl"
:
"~1.3.3"
,
"statuses"
:
"~1.5.0"
,
"unpipe"
:
"~1.0.0"
}
},
"forever-agent"
:
{
"version"
:
"0.6.1"
,
"resolved"
:
"https://registry.npmjs.org/forever-agent/-/forever-agent-0.6.1.tgz"
,
"integrity"
:
"sha1-+8cfDEGt6zf5bFd60e1C2P2sypE="
},
"form-data"
:
{
"version"
:
"2.3.3"
,
"resolved"
:
"https://registry.npmjs.org/form-data/-/form-data-2.3.3.tgz"
,
"integrity"
:
"sha512-1lLKB2Mu3aGP1Q/2eCOx0fNbRMe7XdwktwOruhfqqd0rIJWwN4Dh+E3hrPSlDCXnSR7UtZ1N38rVXm+6+MEhJQ=="
,
"requires"
:
{
"asynckit"
:
"^0.4.0"
,
"combined-stream"
:
"^1.0.6"
,
"mime-types"
:
"^2.1.12"
}
},
"forwarded"
:
{
"version"
:
"0.1.2"
,
"resolved"
:
"https://registry.npmjs.org/forwarded/-/forwarded-0.1.2.tgz"
,
"integrity"
:
"sha1-mMI9qxF1ZXuMBXPozszZGw/xjIQ="
},
"fresh"
:
{
"version"
:
"0.5.2"
,
"resolved"
:
"https://registry.npmjs.org/fresh/-/fresh-0.5.2.tgz"
,
"integrity"
:
"sha1-PYyt2Q2XZWn6g1qx+OSyOhBWBac="
},
"getpass"
:
{
"version"
:
"0.1.7"
,
"resolved"
:
"https://registry.npmjs.org/getpass/-/getpass-0.1.7.tgz"
,
"integrity"
:
"sha1-Xv+OPmhNVprkyysSgmBOi6YhSfo="
,
"requires"
:
{
"assert-plus"
:
"^1.0.0"
}
},
"har-schema"
:
{
"version"
:
"2.0.0"
,
"resolved"
:
"https://registry.npmjs.org/har-schema/-/har-schema-2.0.0.tgz"
,
"integrity"
:
"sha1-qUwiJOvKwEeCoNkDVSHyRzW37JI="
},
"har-validator"
:
{
"version"
:
"5.1.3"
,
"resolved"
:
"https://registry.npmjs.org/har-validator/-/har-validator-5.1.3.tgz"
,
"integrity"
:
"sha512-sNvOCzEQNr/qrvJgc3UG/kD4QtlHycrzwS+6mfTrrSq97BvaYcPZZI1ZSqGSPR73Cxn4LKTD4PttRwfU7jWq5g=="
,
"requires"
:
{
"ajv"
:
"^6.5.5"
,
"har-schema"
:
"^2.0.0"
}
},
"http-errors"
:
{
"version"
:
"1.7.2"
,
"resolved"
:
"https://registry.npmjs.org/http-errors/-/http-errors-1.7.2.tgz"
,
"integrity"
:
"sha512-uUQBt3H/cSIVfch6i1EuPNy/YsRSOUBXTVfZ+yR7Zjez3qjBz6i9+i4zjNaoqcoFVI4lQJ5plg63TvGfRSDCRg=="
,
"requires"
:
{
"depd"
:
"~1.1.2"
,
"inherits"
:
"2.0.3"
,
"setprototypeof"
:
"1.1.1"
,
"statuses"
:
">= 1.5.0 < 2"
,
"toidentifier"
:
"1.0.0"
}
},
"http-signature"
:
{
"version"
:
"1.2.0"
,
"resolved"
:
"https://registry.npmjs.org/http-signature/-/http-signature-1.2.0.tgz"
,
"integrity"
:
"sha1-muzZJRFHcvPZW2WmCruPfBj7rOE="
,
"requires"
:
{
"assert-plus"
:
"^1.0.0"
,
"jsprim"
:
"^1.2.2"
,
"sshpk"
:
"^1.7.0"
}
},
"iconv-lite"
:
{
"version"
:
"0.4.24"
,
"resolved"
:
"https://registry.npmjs.org/iconv-lite/-/iconv-lite-0.4.24.tgz"
,
"integrity"
:
"sha512-v3MXnZAcvnywkTUEZomIActle7RXXeedOR31wwl7VlyoXO4Qi9arvSenNQWne1TcRwhCL1HwLI21bEqdpj8/rA=="
,
"requires"
:
{
"safer-buffer"
:
">= 2.1.2 < 3"
}
},
"inherits"
:
{
"version"
:
"2.0.3"
,
"resolved"
:
"https://registry.npmjs.org/inherits/-/inherits-2.0.3.tgz"
,
"integrity"
:
"sha1-Yzwsg+PaQqUC9SRmAiSA9CCCYd4="
},
"ipaddr.js"
:
{
"version"
:
"1.9.1"
,
"resolved"
:
"https://registry.npmjs.org/ipaddr.js/-/ipaddr.js-1.9.1.tgz"
,
"integrity"
:
"sha512-0KI/607xoxSToH7GjN1FfSbLoU0+btTicjsQSWQlh/hZykN8KpmMf7uYwPW3R+akZ6R/w18ZlXSHBYXiYUPO3g=="
},
"is-typedarray"
:
{
"version"
:
"1.0.0"
,
"resolved"
:
"https://registry.npmjs.org/is-typedarray/-/is-typedarray-1.0.0.tgz"
,
"integrity"
:
"sha1-5HnICFjfDBsR3dppQPlgEfzaSpo="
},
"isstream"
:
{
"version"
:
"0.1.2"
,
"resolved"
:
"https://registry.npmjs.org/isstream/-/isstream-0.1.2.tgz"
,
"integrity"
:
"sha1-R+Y/evVa+m+S4VAOaQ64uFKcCZo="
},
"jsbn"
:
{
"version"
:
"0.1.1"
,
"resolved"
:
"https://registry.npmjs.org/jsbn/-/jsbn-0.1.1.tgz"
,
"integrity"
:
"sha1-peZUwuWi3rXyAdls77yoDA7y9RM="
},
"json-schema"
:
{
"version"
:
"0.2.3"
,
"resolved"
:
"https://registry.npmjs.org/json-schema/-/json-schema-0.2.3.tgz"
,
"integrity"
:
"sha1-tIDIkuWaLwWVTOcnvT8qTogvnhM="
},
"json-schema-traverse"
:
{
"version"
:
"0.4.1"
,
"resolved"
:
"https://registry.npmjs.org/json-schema-traverse/-/json-schema-traverse-0.4.1.tgz"
,
"integrity"
:
"sha512-xbbCH5dCYU5T8LcEhhuh7HJ88HXuW3qsI3Y0zOZFKfZEHcpWiHU/Jxzk629Brsab/mMiHQti9wMP+845RPe3Vg=="
},
"json-stringify-safe"
:
{
"version"
:
"5.0.1"
,
"resolved"
:
"https://registry.npmjs.org/json-stringify-safe/-/json-stringify-safe-5.0.1.tgz"
,
"integrity"
:
"sha1-Epai1Y/UXxmg9s4B1lcB4sc1tus="
},
"jsprim"
:
{
"version"
:
"1.4.1"
,
"resolved"
:
"https://registry.npmjs.org/jsprim/-/jsprim-1.4.1.tgz"
,
"integrity"
:
"sha1-MT5mvB5cwG5Di8G3SZwuXFastqI="
,
"requires"
:
{
"assert-plus"
:
"1.0.0"
,
"extsprintf"
:
"1.3.0"
,
"json-schema"
:
"0.2.3"
,
"verror"
:
"1.10.0"
}
},
"media-typer"
:
{
"version"
:
"0.3.0"
,
"resolved"
:
"https://registry.npmjs.org/media-typer/-/media-typer-0.3.0.tgz"
,
"integrity"
:
"sha1-hxDXrwqmJvj/+hzgAWhUUmMlV0g="
},
"merge-descriptors"
:
{
"version"
:
"1.0.1"
,
"resolved"
:
"https://registry.npmjs.org/merge-descriptors/-/merge-descriptors-1.0.1.tgz"
,
"integrity"
:
"sha1-sAqqVW3YtEVoFQ7J0blT8/kMu2E="
},
"methods"
:
{
"version"
:
"1.1.2"
,
"resolved"
:
"https://registry.npmjs.org/methods/-/methods-1.1.2.tgz"
,
"integrity"
:
"sha1-VSmk1nZUE07cxSZmVoNbD4Ua/O4="
},
"mime"
:
{
"version"
:
"1.6.0"
,
"resolved"
:
"https://registry.npmjs.org/mime/-/mime-1.6.0.tgz"
,
"integrity"
:
"sha512-x0Vn8spI+wuJ1O6S7gnbaQg8Pxh4NNHb7KSINmEWKiPE4RKOplvijn+NkmYmmRgP68mc70j2EbeTFRsrswaQeg=="
},
"mime-db"
:
{
"version"
:
"1.44.0"
,
"resolved"
:
"https://registry.npmjs.org/mime-db/-/mime-db-1.44.0.tgz"
,
"integrity"
:
"sha512-/NOTfLrsPBVeH7YtFPgsVWveuL+4SjjYxaQ1xtM1KMFj7HdxlBlxeyNLzhyJVx7r4rZGJAZ/6lkKCitSc/Nmpg=="
},
"mime-types"
:
{
"version"
:
"2.1.27"
,
"resolved"
:
"https://registry.npmjs.org/mime-types/-/mime-types-2.1.27.tgz"
,
"integrity"
:
"sha512-JIhqnCasI9yD+SsmkquHBxTSEuZdQX5BuQnS2Vc7puQQQ+8yiP5AY5uWhpdv4YL4VM5c6iliiYWPgJ/nJQLp7w=="
,
"requires"
:
{
"mime-db"
:
"1.44.0"
}
},
"ms"
:
{
"version"
:
"2.0.0"
,
"resolved"
:
"https://registry.npmjs.org/ms/-/ms-2.0.0.tgz"
,
"integrity"
:
"sha1-VgiurfwAvmwpAd9fmGF4jeDVl8g="
},
"negotiator"
:
{
"version"
:
"0.6.2"
,
"resolved"
:
"https://registry.npmjs.org/negotiator/-/negotiator-0.6.2.tgz"
,
"integrity"
:
"sha512-hZXc7K2e+PgeI1eDBe/10Ard4ekbfrrqG8Ep+8Jmf4JID2bNg7NvCPOZN+kfF574pFQI7mum2AUqDidoKqcTOw=="
},
"oauth-sign"
:
{
"version"
:
"0.9.0"
,
"resolved"
:
"https://registry.npmjs.org/oauth-sign/-/oauth-sign-0.9.0.tgz"
,
"integrity"
:
"sha512-fexhUFFPTGV8ybAtSIGbV6gOkSv8UtRbDBnAyLQw4QPKkgNlsH2ByPGtMUqdWkos6YCRmAqViwgZrJc/mRDzZQ=="
},
"on-finished"
:
{
"version"
:
"2.3.0"
,
"resolved"
:
"https://registry.npmjs.org/on-finished/-/on-finished-2.3.0.tgz"
,
"integrity"
:
"sha1-IPEzZIGwg811M3mSoWlxqi2QaUc="
,
"requires"
:
{
"ee-first"
:
"1.1.1"
}
},
"parseurl"
:
{
"version"
:
"1.3.3"
,
"resolved"
:
"https://registry.npmjs.org/parseurl/-/parseurl-1.3.3.tgz"
,
"integrity"
:
"sha512-CiyeOxFT/JZyN5m0z9PfXw4SCBJ6Sygz1Dpl0wqjlhDEGGBP1GnsUVEL0p63hoG1fcj3fHynXi9NYO4nWOL+qQ=="
},
"path-to-regexp"
:
{
"version"
:
"0.1.7"
,
"resolved"
:
"https://registry.npmjs.org/path-to-regexp/-/path-to-regexp-0.1.7.tgz"
,
"integrity"
:
"sha1-32BBeABfUi8V60SQ5yR6G/qmf4w="
},
"performance-now"
:
{
"version"
:
"2.1.0"
,
"resolved"
:
"https://registry.npmjs.org/performance-now/-/performance-now-2.1.0.tgz"
,
"integrity"
:
"sha1-Ywn04OX6kT7BxpMHrjZLSzd8nns="
},
"proxy-addr"
:
{
"version"
:
"2.0.6"
,
"resolved"
:
"https://registry.npmjs.org/proxy-addr/-/proxy-addr-2.0.6.tgz"
,
"integrity"
:
"sha512-dh/frvCBVmSsDYzw6n926jv974gddhkFPfiN8hPOi30Wax25QZyZEGveluCgliBnqmuM+UJmBErbAUFIoDbjOw=="
,
"requires"
:
{
"forwarded"
:
"~0.1.2"
,
"ipaddr.js"
:
"1.9.1"
}
},
"psl"
:
{
"version"
:
"1.8.0"
,
"resolved"
:
"https://registry.npmjs.org/psl/-/psl-1.8.0.tgz"
,
"integrity"
:
"sha512-RIdOzyoavK+hA18OGGWDqUTsCLhtA7IcZ/6NCs4fFJaHBDab+pDDmDIByWFRQJq2Cd7r1OoQxBGKOaztq+hjIQ=="
},
"punycode"
:
{
"version"
:
"2.1.1"
,
"resolved"
:
"https://registry.npmjs.org/punycode/-/punycode-2.1.1.tgz"
,
"integrity"
:
"sha512-XRsRjdf+j5ml+y/6GKHPZbrF/8p2Yga0JPtdqTIY2Xe5ohJPD9saDJJLPvp9+NSBprVvevdXZybnj2cv8OEd0A=="
},
"qs"
:
{
"version"
:
"6.7.0"
,
"resolved"
:
"https://registry.npmjs.org/qs/-/qs-6.7.0.tgz"
,
"integrity"
:
"sha512-VCdBRNFTX1fyE7Nb6FYoURo/SPe62QCaAyzJvUjwRaIsc+NePBEniHlvxFmmX56+HZphIGtV0XeCirBtpDrTyQ=="
},
"range-parser"
:
{
"version"
:
"1.2.1"
,
"resolved"
:
"https://registry.npmjs.org/range-parser/-/range-parser-1.2.1.tgz"
,
"integrity"
:
"sha512-Hrgsx+orqoygnmhFbKaHE6c296J+HTAQXoxEF6gNupROmmGJRoyzfG3ccAveqCBrwr/2yxQ5BVd/GTl5agOwSg=="
},
"raw-body"
:
{
"version"
:
"2.4.0"
,
"resolved"
:
"https://registry.npmjs.org/raw-body/-/raw-body-2.4.0.tgz"
,
"integrity"
:
"sha512-4Oz8DUIwdvoa5qMJelxipzi/iJIi40O5cGV1wNYp5hvZP8ZN0T+jiNkL0QepXs+EsQ9XJ8ipEDoiH70ySUJP3Q=="
,
"requires"
:
{
"bytes"
:
"3.1.0"
,
"http-errors"
:
"1.7.2"
,
"iconv-lite"
:
"0.4.24"
,
"unpipe"
:
"1.0.0"
}
},
"request"
:
{
"version"
:
"2.88.2"
,
"resolved"
:
"https://registry.npmjs.org/request/-/request-2.88.2.tgz"
,
"integrity"
:
"sha512-MsvtOrfG9ZcrOwAW+Qi+F6HbD0CWXEh9ou77uOb7FM2WPhwT7smM833PzanhJLsgXjN89Ir6V2PczXNnMpwKhw=="
,
"requires"
:
{
"aws-sign2"
:
"~0.7.0"
,
"aws4"
:
"^1.8.0"
,
"caseless"
:
"~0.12.0"
,
"combined-stream"
:
"~1.0.6"
,
"extend"
:
"~3.0.2"
,
"forever-agent"
:
"~0.6.1"
,
"form-data"
:
"~2.3.2"
,
"har-validator"
:
"~5.1.3"
,
"http-signature"
:
"~1.2.0"
,
"is-typedarray"
:
"~1.0.0"
,
"isstream"
:
"~0.1.2"
,
"json-stringify-safe"
:
"~5.0.1"
,
"mime-types"
:
"~2.1.19"
,
"oauth-sign"
:
"~0.9.0"
,
"performance-now"
:
"^2.1.0"
,
"qs"
:
"~6.5.2"
,
"safe-buffer"
:
"^5.1.2"
,
"tough-cookie"
:
"~2.5.0"
,
"tunnel-agent"
:
"^0.6.0"
,
"uuid"
:
"^3.3.2"
},
"dependencies"
:
{
"qs"
:
{
"version"
:
"6.5.2"
,
"resolved"
:
"https://registry.npmjs.org/qs/-/qs-6.5.2.tgz"
,
"integrity"
:
"sha512-N5ZAX4/LxJmF+7wN74pUD6qAh9/wnvdQcjq9TZjevvXzSUo7bfmw91saqMjzGS2xq91/odN2dW/WOl7qQHNDGA=="
}
}
},
"safe-buffer"
:
{
"version"
:
"5.1.2"
,
"resolved"
:
"https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.1.2.tgz"
,
"integrity"
:
"sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g=="
},
"safer-buffer"
:
{
"version"
:
"2.1.2"
,
"resolved"
:
"https://registry.npmjs.org/safer-buffer/-/safer-buffer-2.1.2.tgz"
,
"integrity"
:
"sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg=="
},
"send"
:
{
"version"
:
"0.17.1"
,
"resolved"
:
"https://registry.npmjs.org/send/-/send-0.17.1.tgz"
,
"integrity"
:
"sha512-BsVKsiGcQMFwT8UxypobUKyv7irCNRHk1T0G680vk88yf6LBByGcZJOTJCrTP2xVN6yI+XjPJcNuE3V4fT9sAg=="
,
"requires"
:
{
"debug"
:
"2.6.9"
,
"depd"
:
"~1.1.2"
,
"destroy"
:
"~1.0.4"
,
"encodeurl"
:
"~1.0.2"
,
"escape-html"
:
"~1.0.3"
,
"etag"
:
"~1.8.1"
,
"fresh"
:
"0.5.2"
,
"http-errors"
:
"~1.7.2"
,
"mime"
:
"1.6.0"
,
"ms"
:
"2.1.1"
,
"on-finished"
:
"~2.3.0"
,
"range-parser"
:
"~1.2.1"
,
"statuses"
:
"~1.5.0"
},
"dependencies"
:
{
"ms"
:
{
"version"
:
"2.1.1"
,
"resolved"
:
"https://registry.npmjs.org/ms/-/ms-2.1.1.tgz"
,
"integrity"
:
"sha512-tgp+dl5cGk28utYktBsrFqA7HKgrhgPsg6Z/EfhWI4gl1Hwq8B/GmY/0oXZ6nF8hDVesS/FpnYaD/kOWhYQvyg=="
}
}
},
"serve-static"
:
{
"version"
:
"1.14.1"
,
"resolved"
:
"https://registry.npmjs.org/serve-static/-/serve-static-1.14.1.tgz"
,
"integrity"
:
"sha512-JMrvUwE54emCYWlTI+hGrGv5I8dEwmco/00EvkzIIsR7MqrHonbD9pO2MOfFnpFntl7ecpZs+3mW+XbQZu9QCg=="
,
"requires"
:
{
"encodeurl"
:
"~1.0.2"
,
"escape-html"
:
"~1.0.3"
,
"parseurl"
:
"~1.3.3"
,
"send"
:
"0.17.1"
}
},
"setprototypeof"
:
{
"version"
:
"1.1.1"
,
"resolved"
:
"https://registry.npmjs.org/setprototypeof/-/setprototypeof-1.1.1.tgz"
,
"integrity"
:
"sha512-JvdAWfbXeIGaZ9cILp38HntZSFSo3mWg6xGcJJsd+d4aRMOqauag1C63dJfDw7OaMYwEbHMOxEZ1lqVRYP2OAw=="
},
"sshpk"
:
{
"version"
:
"1.16.1"
,
"resolved"
:
"https://registry.npmjs.org/sshpk/-/sshpk-1.16.1.tgz"
,
"integrity"
:
"sha512-HXXqVUq7+pcKeLqqZj6mHFUMvXtOJt1uoUx09pFW6011inTMxqI8BA8PM95myrIyyKwdnzjdFjLiE6KBPVtJIg=="
,
"requires"
:
{
"asn1"
:
"~0.2.3"
,
"assert-plus"
:
"^1.0.0"
,
"bcrypt-pbkdf"
:
"^1.0.0"
,
"dashdash"
:
"^1.12.0"
,
"ecc-jsbn"
:
"~0.1.1"
,
"getpass"
:
"^0.1.1"
,
"jsbn"
:
"~0.1.0"
,
"safer-buffer"
:
"^2.0.2"
,
"tweetnacl"
:
"~0.14.0"
}
},
"statuses"
:
{
"version"
:
"1.5.0"
,
"resolved"
:
"https://registry.npmjs.org/statuses/-/statuses-1.5.0.tgz"
,
"integrity"
:
"sha1-Fhx9rBd2Wf2YEfQ3cfqZOBR4Yow="
},
"toidentifier"
:
{
"version"
:
"1.0.0"
,
"resolved"
:
"https://registry.npmjs.org/toidentifier/-/toidentifier-1.0.0.tgz"
,
"integrity"
:
"sha512-yaOH/Pk/VEhBWWTlhI+qXxDFXlejDGcQipMlyxda9nthulaxLZUNcUqFxokp0vcYnvteJln5FNQDRrxj3YcbVw=="
},
"tough-cookie"
:
{
"version"
:
"2.5.0"
,
"resolved"
:
"https://registry.npmjs.org/tough-cookie/-/tough-cookie-2.5.0.tgz"
,
"integrity"
:
"sha512-nlLsUzgm1kfLXSXfRZMc1KLAugd4hqJHDTvc2hDIwS3mZAfMEuMbc03SujMF+GEcpaX/qboeycw6iO8JwVv2+g=="
,
"requires"
:
{
"psl"
:
"^1.1.28"
,
"punycode"
:
"^2.1.1"
}
},
"tunnel-agent"
:
{
"version"
:
"0.6.0"
,
"resolved"
:
"https://registry.npmjs.org/tunnel-agent/-/tunnel-agent-0.6.0.tgz"
,
"integrity"
:
"sha1-J6XeoGs2sEoKmWZ3SykIaPD8QP0="
,
"requires"
:
{
"safe-buffer"
:
"^5.0.1"
}
},
"tweetnacl"
:
{
"version"
:
"0.14.5"
,
"resolved"
:
"https://registry.npmjs.org/tweetnacl/-/tweetnacl-0.14.5.tgz"
,
"integrity"
:
"sha1-WuaBd/GS1EViadEIr6k/+HQ/T2Q="
},
"type-is"
:
{
"version"
:
"1.6.18"
,
"resolved"
:
"https://registry.npmjs.org/type-is/-/type-is-1.6.18.tgz"
,
"integrity"
:
"sha512-TkRKr9sUTxEH8MdfuCSP7VizJyzRNMjj2J2do2Jr3Kym598JVdEksuzPQCnlFPW4ky9Q+iA+ma9BGm06XQBy8g=="
,
"requires"
:
{
"media-typer"
:
"0.3.0"
,
"mime-types"
:
"~2.1.24"
}
},
"unpipe"
:
{
"version"
:
"1.0.0"
,
"resolved"
:
"https://registry.npmjs.org/unpipe/-/unpipe-1.0.0.tgz"
,
"integrity"
:
"sha1-sr9O6FFKrmFltIF4KdIbLvSZBOw="
},
"uri-js"
:
{
"version"
:
"4.2.2"
,
"resolved"
:
"https://registry.npmjs.org/uri-js/-/uri-js-4.2.2.tgz"
,
"integrity"
:
"sha512-KY9Frmirql91X2Qgjry0Wd4Y+YTdrdZheS8TFwvkbLWf/G5KNJDCh6pKL5OZctEW4+0Baa5idK2ZQuELRwPznQ=="
,
"requires"
:
{
"punycode"
:
"^2.1.0"
}
},
"utils-merge"
:
{
"version"
:
"1.0.1"
,
"resolved"
:
"https://registry.npmjs.org/utils-merge/-/utils-merge-1.0.1.tgz"
,
"integrity"
:
"sha1-n5VxD1CiZ5R7LMwSR0HBAoQn5xM="
},
"uuid"
:
{
"version"
:
"3.4.0"
,
"resolved"
:
"https://registry.npmjs.org/uuid/-/uuid-3.4.0.tgz"
,
"integrity"
:
"sha512-HjSDRw6gZE5JMggctHBcjVak08+KEVhSIiDzFnT9S9aegmp85S/bReBVTb4QTFaRNptJ9kuYaNhnbNEOkbKb/A=="
},
"vary"
:
{
"version"
:
"1.1.2"
,
"resolved"
:
"https://registry.npmjs.org/vary/-/vary-1.1.2.tgz"
,
"integrity"
:
"sha1-IpnwLG3tMNSllhsLn3RSShj2NPw="
},
"verror"
:
{
"version"
:
"1.10.0"
,
"resolved"
:
"https://registry.npmjs.org/verror/-/verror-1.10.0.tgz"
,
"integrity"
:
"sha1-OhBcoXBTr1XW4nDB+CiGguGNpAA="
,
"requires"
:
{
"assert-plus"
:
"^1.0.0"
,
"core-util-is"
:
"1.0.2"
,
"extsprintf"
:
"^1.2.0"
}
}
}
}
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/messenger/reply/package.json
0 → 100644
View file @
9fa45f8
{
"name"
:
"reply"
,
"version"
:
"1.0.0"
,
"description"
:
""
,
"main"
:
"app.js"
,
"scripts"
:
{
"test"
:
"echo
\"
Error: no test specified
\"
&& exit 1"
},
"author"
:
""
,
"license"
:
"ISC"
,
"dependencies"
:
{
"body-parser"
:
"^1.19.0"
,
"express"
:
"^4.17.1"
,
"request"
:
"^2.88.2"
}
}
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/messenger/ssl/app.js
0 → 100644
View file @
9fa45f8
const
express
=
require
(
'express'
);
const
fs
=
require
(
'fs'
);
const
path
=
require
(
'path'
);
const
HTTPS
=
require
(
'https'
);
const
app
=
express
();
// 본인이 소유한 도메인으로 변경해야 함
// www 붙여야 함
const
domain
=
"www.stagefive.tk"
const
sslport
=
23023
;
app
.
get
(
'/'
,
function
(
req
,
res
)
{
res
.
send
(
'Hello World'
);
})
try
{
const
option
=
{
ca
:
fs
.
readFileSync
(
'/etc/letsencrypt/live/'
+
domain
+
'/fullchain.pem'
),
key
:
fs
.
readFileSync
(
path
.
resolve
(
process
.
cwd
(),
'/etc/letsencrypt/live/'
+
domain
+
'/privkey.pem'
),
'utf8'
).
toString
(),
cert
:
fs
.
readFileSync
(
path
.
resolve
(
process
.
cwd
(),
'/etc/letsencrypt/live/'
+
domain
+
'/cert.pem'
),
'utf8'
).
toString
(),
};
HTTPS
.
createServer
(
option
,
app
).
listen
(
sslport
,
()
=>
{
console
.
log
(
`[HTTPS] Server is started on port
${
sslport
}
`
);
});
}
catch
(
error
)
{
console
.
log
(
'[HTTPS] HTTPS 오류가 발생하였습니다. HTTPS 서버는 실행되지 않습니다.'
);
console
.
log
(
error
);
}
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/messenger/ssl/package-lock.json
0 → 100644
View file @
9fa45f8
{
"name"
:
"ssl"
,
"version"
:
"1.0.0"
,
"lockfileVersion"
:
1
,
"requires"
:
true
,
"dependencies"
:
{
"accepts"
:
{
"version"
:
"1.3.7"
,
"resolved"
:
"https://registry.npmjs.org/accepts/-/accepts-1.3.7.tgz"
,
"integrity"
:
"sha512-Il80Qs2WjYlJIBNzNkK6KYqlVMTbZLXgHx2oT0pU/fjRHyEp+PEfEPY0R3WCwAGVOtauxh1hOxNgIf5bv7dQpA=="
,
"requires"
:
{
"mime-types"
:
"~2.1.24"
,
"negotiator"
:
"0.6.2"
}
},
"array-flatten"
:
{
"version"
:
"1.1.1"
,
"resolved"
:
"https://registry.npmjs.org/array-flatten/-/array-flatten-1.1.1.tgz"
,
"integrity"
:
"sha1-ml9pkFGx5wczKPKgCJaLZOopVdI="
},
"body-parser"
:
{
"version"
:
"1.19.0"
,
"resolved"
:
"https://registry.npmjs.org/body-parser/-/body-parser-1.19.0.tgz"
,
"integrity"
:
"sha512-dhEPs72UPbDnAQJ9ZKMNTP6ptJaionhP5cBb541nXPlW60Jepo9RV/a4fX4XWW9CuFNK22krhrj1+rgzifNCsw=="
,
"requires"
:
{
"bytes"
:
"3.1.0"
,
"content-type"
:
"~1.0.4"
,
"debug"
:
"2.6.9"
,
"depd"
:
"~1.1.2"
,
"http-errors"
:
"1.7.2"
,
"iconv-lite"
:
"0.4.24"
,
"on-finished"
:
"~2.3.0"
,
"qs"
:
"6.7.0"
,
"raw-body"
:
"2.4.0"
,
"type-is"
:
"~1.6.17"
}
},
"bytes"
:
{
"version"
:
"3.1.0"
,
"resolved"
:
"https://registry.npmjs.org/bytes/-/bytes-3.1.0.tgz"
,
"integrity"
:
"sha512-zauLjrfCG+xvoyaqLoV8bLVXXNGC4JqlxFCutSDWA6fJrTo2ZuvLYTqZ7aHBLZSMOopbzwv8f+wZcVzfVTI2Dg=="
},
"content-disposition"
:
{
"version"
:
"0.5.3"
,
"resolved"
:
"https://registry.npmjs.org/content-disposition/-/content-disposition-0.5.3.tgz"
,
"integrity"
:
"sha512-ExO0774ikEObIAEV9kDo50o+79VCUdEB6n6lzKgGwupcVeRlhrj3qGAfwq8G6uBJjkqLrhT0qEYFcWng8z1z0g=="
,
"requires"
:
{
"safe-buffer"
:
"5.1.2"
}
},
"content-type"
:
{
"version"
:
"1.0.4"
,
"resolved"
:
"https://registry.npmjs.org/content-type/-/content-type-1.0.4.tgz"
,
"integrity"
:
"sha512-hIP3EEPs8tB9AT1L+NUqtwOAps4mk2Zob89MWXMHjHWg9milF/j4osnnQLXBCBFBk/tvIG/tUc9mOUJiPBhPXA=="
},
"cookie"
:
{
"version"
:
"0.4.0"
,
"resolved"
:
"https://registry.npmjs.org/cookie/-/cookie-0.4.0.tgz"
,
"integrity"
:
"sha512-+Hp8fLp57wnUSt0tY0tHEXh4voZRDnoIrZPqlo3DPiI4y9lwg/jqx+1Om94/W6ZaPDOUbnjOt/99w66zk+l1Xg=="
},
"cookie-signature"
:
{
"version"
:
"1.0.6"
,
"resolved"
:
"https://registry.npmjs.org/cookie-signature/-/cookie-signature-1.0.6.tgz"
,
"integrity"
:
"sha1-4wOogrNCzD7oylE6eZmXNNqzriw="
},
"debug"
:
{
"version"
:
"2.6.9"
,
"resolved"
:
"https://registry.npmjs.org/debug/-/debug-2.6.9.tgz"
,
"integrity"
:
"sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA=="
,
"requires"
:
{
"ms"
:
"2.0.0"
}
},
"depd"
:
{
"version"
:
"1.1.2"
,
"resolved"
:
"https://registry.npmjs.org/depd/-/depd-1.1.2.tgz"
,
"integrity"
:
"sha1-m81S4UwJd2PnSbJ0xDRu0uVgtak="
},
"destroy"
:
{
"version"
:
"1.0.4"
,
"resolved"
:
"https://registry.npmjs.org/destroy/-/destroy-1.0.4.tgz"
,
"integrity"
:
"sha1-l4hXRCxEdJ5CBmE+N5RiBYJqvYA="
},
"ee-first"
:
{
"version"
:
"1.1.1"
,
"resolved"
:
"https://registry.npmjs.org/ee-first/-/ee-first-1.1.1.tgz"
,
"integrity"
:
"sha1-WQxhFWsK4vTwJVcyoViyZrxWsh0="
},
"encodeurl"
:
{
"version"
:
"1.0.2"
,
"resolved"
:
"https://registry.npmjs.org/encodeurl/-/encodeurl-1.0.2.tgz"
,
"integrity"
:
"sha1-rT/0yG7C0CkyL1oCw6mmBslbP1k="
},
"escape-html"
:
{
"version"
:
"1.0.3"
,
"resolved"
:
"https://registry.npmjs.org/escape-html/-/escape-html-1.0.3.tgz"
,
"integrity"
:
"sha1-Aljq5NPQwJdN4cFpGI7wBR0dGYg="
},
"etag"
:
{
"version"
:
"1.8.1"
,
"resolved"
:
"https://registry.npmjs.org/etag/-/etag-1.8.1.tgz"
,
"integrity"
:
"sha1-Qa4u62XvpiJorr/qg6x9eSmbCIc="
},
"express"
:
{
"version"
:
"4.17.1"
,
"resolved"
:
"https://registry.npmjs.org/express/-/express-4.17.1.tgz"
,
"integrity"
:
"sha512-mHJ9O79RqluphRrcw2X/GTh3k9tVv8YcoyY4Kkh4WDMUYKRZUq0h1o0w2rrrxBqM7VoeUVqgb27xlEMXTnYt4g=="
,
"requires"
:
{
"accepts"
:
"~1.3.7"
,
"array-flatten"
:
"1.1.1"
,
"body-parser"
:
"1.19.0"
,
"content-disposition"
:
"0.5.3"
,
"content-type"
:
"~1.0.4"
,
"cookie"
:
"0.4.0"
,
"cookie-signature"
:
"1.0.6"
,
"debug"
:
"2.6.9"
,
"depd"
:
"~1.1.2"
,
"encodeurl"
:
"~1.0.2"
,
"escape-html"
:
"~1.0.3"
,
"etag"
:
"~1.8.1"
,
"finalhandler"
:
"~1.1.2"
,
"fresh"
:
"0.5.2"
,
"merge-descriptors"
:
"1.0.1"
,
"methods"
:
"~1.1.2"
,
"on-finished"
:
"~2.3.0"
,
"parseurl"
:
"~1.3.3"
,
"path-to-regexp"
:
"0.1.7"
,
"proxy-addr"
:
"~2.0.5"
,
"qs"
:
"6.7.0"
,
"range-parser"
:
"~1.2.1"
,
"safe-buffer"
:
"5.1.2"
,
"send"
:
"0.17.1"
,
"serve-static"
:
"1.14.1"
,
"setprototypeof"
:
"1.1.1"
,
"statuses"
:
"~1.5.0"
,
"type-is"
:
"~1.6.18"
,
"utils-merge"
:
"1.0.1"
,
"vary"
:
"~1.1.2"
}
},
"finalhandler"
:
{
"version"
:
"1.1.2"
,
"resolved"
:
"https://registry.npmjs.org/finalhandler/-/finalhandler-1.1.2.tgz"
,
"integrity"
:
"sha512-aAWcW57uxVNrQZqFXjITpW3sIUQmHGG3qSb9mUah9MgMC4NeWhNOlNjXEYq3HjRAvL6arUviZGGJsBg6z0zsWA=="
,
"requires"
:
{
"debug"
:
"2.6.9"
,
"encodeurl"
:
"~1.0.2"
,
"escape-html"
:
"~1.0.3"
,
"on-finished"
:
"~2.3.0"
,
"parseurl"
:
"~1.3.3"
,
"statuses"
:
"~1.5.0"
,
"unpipe"
:
"~1.0.0"
}
},
"forwarded"
:
{
"version"
:
"0.1.2"
,
"resolved"
:
"https://registry.npmjs.org/forwarded/-/forwarded-0.1.2.tgz"
,
"integrity"
:
"sha1-mMI9qxF1ZXuMBXPozszZGw/xjIQ="
},
"fresh"
:
{
"version"
:
"0.5.2"
,
"resolved"
:
"https://registry.npmjs.org/fresh/-/fresh-0.5.2.tgz"
,
"integrity"
:
"sha1-PYyt2Q2XZWn6g1qx+OSyOhBWBac="
},
"http-errors"
:
{
"version"
:
"1.7.2"
,
"resolved"
:
"https://registry.npmjs.org/http-errors/-/http-errors-1.7.2.tgz"
,
"integrity"
:
"sha512-uUQBt3H/cSIVfch6i1EuPNy/YsRSOUBXTVfZ+yR7Zjez3qjBz6i9+i4zjNaoqcoFVI4lQJ5plg63TvGfRSDCRg=="
,
"requires"
:
{
"depd"
:
"~1.1.2"
,
"inherits"
:
"2.0.3"
,
"setprototypeof"
:
"1.1.1"
,
"statuses"
:
">= 1.5.0 < 2"
,
"toidentifier"
:
"1.0.0"
}
},
"iconv-lite"
:
{
"version"
:
"0.4.24"
,
"resolved"
:
"https://registry.npmjs.org/iconv-lite/-/iconv-lite-0.4.24.tgz"
,
"integrity"
:
"sha512-v3MXnZAcvnywkTUEZomIActle7RXXeedOR31wwl7VlyoXO4Qi9arvSenNQWne1TcRwhCL1HwLI21bEqdpj8/rA=="
,
"requires"
:
{
"safer-buffer"
:
">= 2.1.2 < 3"
}
},
"inherits"
:
{
"version"
:
"2.0.3"
,
"resolved"
:
"https://registry.npmjs.org/inherits/-/inherits-2.0.3.tgz"
,
"integrity"
:
"sha1-Yzwsg+PaQqUC9SRmAiSA9CCCYd4="
},
"ipaddr.js"
:
{
"version"
:
"1.9.1"
,
"resolved"
:
"https://registry.npmjs.org/ipaddr.js/-/ipaddr.js-1.9.1.tgz"
,
"integrity"
:
"sha512-0KI/607xoxSToH7GjN1FfSbLoU0+btTicjsQSWQlh/hZykN8KpmMf7uYwPW3R+akZ6R/w18ZlXSHBYXiYUPO3g=="
},
"media-typer"
:
{
"version"
:
"0.3.0"
,
"resolved"
:
"https://registry.npmjs.org/media-typer/-/media-typer-0.3.0.tgz"
,
"integrity"
:
"sha1-hxDXrwqmJvj/+hzgAWhUUmMlV0g="
},
"merge-descriptors"
:
{
"version"
:
"1.0.1"
,
"resolved"
:
"https://registry.npmjs.org/merge-descriptors/-/merge-descriptors-1.0.1.tgz"
,
"integrity"
:
"sha1-sAqqVW3YtEVoFQ7J0blT8/kMu2E="
},
"methods"
:
{
"version"
:
"1.1.2"
,
"resolved"
:
"https://registry.npmjs.org/methods/-/methods-1.1.2.tgz"
,
"integrity"
:
"sha1-VSmk1nZUE07cxSZmVoNbD4Ua/O4="
},
"mime"
:
{
"version"
:
"1.6.0"
,
"resolved"
:
"https://registry.npmjs.org/mime/-/mime-1.6.0.tgz"
,
"integrity"
:
"sha512-x0Vn8spI+wuJ1O6S7gnbaQg8Pxh4NNHb7KSINmEWKiPE4RKOplvijn+NkmYmmRgP68mc70j2EbeTFRsrswaQeg=="
},
"mime-db"
:
{
"version"
:
"1.44.0"
,
"resolved"
:
"https://registry.npmjs.org/mime-db/-/mime-db-1.44.0.tgz"
,
"integrity"
:
"sha512-/NOTfLrsPBVeH7YtFPgsVWveuL+4SjjYxaQ1xtM1KMFj7HdxlBlxeyNLzhyJVx7r4rZGJAZ/6lkKCitSc/Nmpg=="
},
"mime-types"
:
{
"version"
:
"2.1.27"
,
"resolved"
:
"https://registry.npmjs.org/mime-types/-/mime-types-2.1.27.tgz"
,
"integrity"
:
"sha512-JIhqnCasI9yD+SsmkquHBxTSEuZdQX5BuQnS2Vc7puQQQ+8yiP5AY5uWhpdv4YL4VM5c6iliiYWPgJ/nJQLp7w=="
,
"requires"
:
{
"mime-db"
:
"1.44.0"
}
},
"ms"
:
{
"version"
:
"2.0.0"
,
"resolved"
:
"https://registry.npmjs.org/ms/-/ms-2.0.0.tgz"
,
"integrity"
:
"sha1-VgiurfwAvmwpAd9fmGF4jeDVl8g="
},
"negotiator"
:
{
"version"
:
"0.6.2"
,
"resolved"
:
"https://registry.npmjs.org/negotiator/-/negotiator-0.6.2.tgz"
,
"integrity"
:
"sha512-hZXc7K2e+PgeI1eDBe/10Ard4ekbfrrqG8Ep+8Jmf4JID2bNg7NvCPOZN+kfF574pFQI7mum2AUqDidoKqcTOw=="
},
"on-finished"
:
{
"version"
:
"2.3.0"
,
"resolved"
:
"https://registry.npmjs.org/on-finished/-/on-finished-2.3.0.tgz"
,
"integrity"
:
"sha1-IPEzZIGwg811M3mSoWlxqi2QaUc="
,
"requires"
:
{
"ee-first"
:
"1.1.1"
}
},
"parseurl"
:
{
"version"
:
"1.3.3"
,
"resolved"
:
"https://registry.npmjs.org/parseurl/-/parseurl-1.3.3.tgz"
,
"integrity"
:
"sha512-CiyeOxFT/JZyN5m0z9PfXw4SCBJ6Sygz1Dpl0wqjlhDEGGBP1GnsUVEL0p63hoG1fcj3fHynXi9NYO4nWOL+qQ=="
},
"path-to-regexp"
:
{
"version"
:
"0.1.7"
,
"resolved"
:
"https://registry.npmjs.org/path-to-regexp/-/path-to-regexp-0.1.7.tgz"
,
"integrity"
:
"sha1-32BBeABfUi8V60SQ5yR6G/qmf4w="
},
"proxy-addr"
:
{
"version"
:
"2.0.6"
,
"resolved"
:
"https://registry.npmjs.org/proxy-addr/-/proxy-addr-2.0.6.tgz"
,
"integrity"
:
"sha512-dh/frvCBVmSsDYzw6n926jv974gddhkFPfiN8hPOi30Wax25QZyZEGveluCgliBnqmuM+UJmBErbAUFIoDbjOw=="
,
"requires"
:
{
"forwarded"
:
"~0.1.2"
,
"ipaddr.js"
:
"1.9.1"
}
},
"qs"
:
{
"version"
:
"6.7.0"
,
"resolved"
:
"https://registry.npmjs.org/qs/-/qs-6.7.0.tgz"
,
"integrity"
:
"sha512-VCdBRNFTX1fyE7Nb6FYoURo/SPe62QCaAyzJvUjwRaIsc+NePBEniHlvxFmmX56+HZphIGtV0XeCirBtpDrTyQ=="
},
"range-parser"
:
{
"version"
:
"1.2.1"
,
"resolved"
:
"https://registry.npmjs.org/range-parser/-/range-parser-1.2.1.tgz"
,
"integrity"
:
"sha512-Hrgsx+orqoygnmhFbKaHE6c296J+HTAQXoxEF6gNupROmmGJRoyzfG3ccAveqCBrwr/2yxQ5BVd/GTl5agOwSg=="
},
"raw-body"
:
{
"version"
:
"2.4.0"
,
"resolved"
:
"https://registry.npmjs.org/raw-body/-/raw-body-2.4.0.tgz"
,
"integrity"
:
"sha512-4Oz8DUIwdvoa5qMJelxipzi/iJIi40O5cGV1wNYp5hvZP8ZN0T+jiNkL0QepXs+EsQ9XJ8ipEDoiH70ySUJP3Q=="
,
"requires"
:
{
"bytes"
:
"3.1.0"
,
"http-errors"
:
"1.7.2"
,
"iconv-lite"
:
"0.4.24"
,
"unpipe"
:
"1.0.0"
}
},
"safe-buffer"
:
{
"version"
:
"5.1.2"
,
"resolved"
:
"https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.1.2.tgz"
,
"integrity"
:
"sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g=="
},
"safer-buffer"
:
{
"version"
:
"2.1.2"
,
"resolved"
:
"https://registry.npmjs.org/safer-buffer/-/safer-buffer-2.1.2.tgz"
,
"integrity"
:
"sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg=="
},
"send"
:
{
"version"
:
"0.17.1"
,
"resolved"
:
"https://registry.npmjs.org/send/-/send-0.17.1.tgz"
,
"integrity"
:
"sha512-BsVKsiGcQMFwT8UxypobUKyv7irCNRHk1T0G680vk88yf6LBByGcZJOTJCrTP2xVN6yI+XjPJcNuE3V4fT9sAg=="
,
"requires"
:
{
"debug"
:
"2.6.9"
,
"depd"
:
"~1.1.2"
,
"destroy"
:
"~1.0.4"
,
"encodeurl"
:
"~1.0.2"
,
"escape-html"
:
"~1.0.3"
,
"etag"
:
"~1.8.1"
,
"fresh"
:
"0.5.2"
,
"http-errors"
:
"~1.7.2"
,
"mime"
:
"1.6.0"
,
"ms"
:
"2.1.1"
,
"on-finished"
:
"~2.3.0"
,
"range-parser"
:
"~1.2.1"
,
"statuses"
:
"~1.5.0"
},
"dependencies"
:
{
"ms"
:
{
"version"
:
"2.1.1"
,
"resolved"
:
"https://registry.npmjs.org/ms/-/ms-2.1.1.tgz"
,
"integrity"
:
"sha512-tgp+dl5cGk28utYktBsrFqA7HKgrhgPsg6Z/EfhWI4gl1Hwq8B/GmY/0oXZ6nF8hDVesS/FpnYaD/kOWhYQvyg=="
}
}
},
"serve-static"
:
{
"version"
:
"1.14.1"
,
"resolved"
:
"https://registry.npmjs.org/serve-static/-/serve-static-1.14.1.tgz"
,
"integrity"
:
"sha512-JMrvUwE54emCYWlTI+hGrGv5I8dEwmco/00EvkzIIsR7MqrHonbD9pO2MOfFnpFntl7ecpZs+3mW+XbQZu9QCg=="
,
"requires"
:
{
"encodeurl"
:
"~1.0.2"
,
"escape-html"
:
"~1.0.3"
,
"parseurl"
:
"~1.3.3"
,
"send"
:
"0.17.1"
}
},
"setprototypeof"
:
{
"version"
:
"1.1.1"
,
"resolved"
:
"https://registry.npmjs.org/setprototypeof/-/setprototypeof-1.1.1.tgz"
,
"integrity"
:
"sha512-JvdAWfbXeIGaZ9cILp38HntZSFSo3mWg6xGcJJsd+d4aRMOqauag1C63dJfDw7OaMYwEbHMOxEZ1lqVRYP2OAw=="
},
"statuses"
:
{
"version"
:
"1.5.0"
,
"resolved"
:
"https://registry.npmjs.org/statuses/-/statuses-1.5.0.tgz"
,
"integrity"
:
"sha1-Fhx9rBd2Wf2YEfQ3cfqZOBR4Yow="
},
"toidentifier"
:
{
"version"
:
"1.0.0"
,
"resolved"
:
"https://registry.npmjs.org/toidentifier/-/toidentifier-1.0.0.tgz"
,
"integrity"
:
"sha512-yaOH/Pk/VEhBWWTlhI+qXxDFXlejDGcQipMlyxda9nthulaxLZUNcUqFxokp0vcYnvteJln5FNQDRrxj3YcbVw=="
},
"type-is"
:
{
"version"
:
"1.6.18"
,
"resolved"
:
"https://registry.npmjs.org/type-is/-/type-is-1.6.18.tgz"
,
"integrity"
:
"sha512-TkRKr9sUTxEH8MdfuCSP7VizJyzRNMjj2J2do2Jr3Kym598JVdEksuzPQCnlFPW4ky9Q+iA+ma9BGm06XQBy8g=="
,
"requires"
:
{
"media-typer"
:
"0.3.0"
,
"mime-types"
:
"~2.1.24"
}
},
"unpipe"
:
{
"version"
:
"1.0.0"
,
"resolved"
:
"https://registry.npmjs.org/unpipe/-/unpipe-1.0.0.tgz"
,
"integrity"
:
"sha1-sr9O6FFKrmFltIF4KdIbLvSZBOw="
},
"utils-merge"
:
{
"version"
:
"1.0.1"
,
"resolved"
:
"https://registry.npmjs.org/utils-merge/-/utils-merge-1.0.1.tgz"
,
"integrity"
:
"sha1-n5VxD1CiZ5R7LMwSR0HBAoQn5xM="
},
"vary"
:
{
"version"
:
"1.1.2"
,
"resolved"
:
"https://registry.npmjs.org/vary/-/vary-1.1.2.tgz"
,
"integrity"
:
"sha1-IpnwLG3tMNSllhsLn3RSShj2NPw="
}
}
}
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/messenger/ssl/package.json
0 → 100644
View file @
9fa45f8
{
"name"
:
"ssl"
,
"version"
:
"1.0.0"
,
"description"
:
""
,
"main"
:
"app.js"
,
"scripts"
:
{
"test"
:
"echo
\"
Error: no test specified
\"
&& exit 1"
},
"author"
:
""
,
"license"
:
"ISC"
,
"dependencies"
:
{
"express"
:
"^4.17.1"
}
}
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/messenger/trans/app.js
0 → 100644
View file @
9fa45f8
var
express
=
require
(
'express'
);
const
request
=
require
(
'request'
);
const
TARGET_URL
=
'https://api.line.me/v2/bot/message/reply'
const
TOKEN
=
'채널 토큰'
const
PAPAGO_URL
=
'https://openapi.naver.com/v1/papago/n2mt'
const
PAPAGO_ID
=
'파파고 ID'
const
PAPAGO_SECRET
=
'파파고 Client Secret'
const
fs
=
require
(
'fs'
);
const
path
=
require
(
'path'
);
const
HTTPS
=
require
(
'https'
);
const
domain
=
"도메인 명"
const
sslport
=
23023
;
const
bodyParser
=
require
(
'body-parser'
);
var
app
=
express
();
app
.
use
(
bodyParser
.
json
());
app
.
post
(
'/hook'
,
function
(
req
,
res
)
{
var
eventObj
=
req
.
body
.
events
[
0
];
var
source
=
eventObj
.
source
;
var
message
=
eventObj
.
message
;
// request log
console
.
log
(
'======================'
,
new
Date
()
,
'======================'
);
console
.
log
(
'[request]'
,
req
.
body
);
console
.
log
(
'[request source] '
,
eventObj
.
source
);
console
.
log
(
'[request message]'
,
eventObj
.
message
);
trans
(
eventObj
.
replyToken
,
eventObj
.
message
.
text
);
res
.
sendStatus
(
200
);
});
function
trans
(
replyToken
,
message
)
{
request
.
post
(
{
url
:
PAPAGO_URL
,
headers
:
{
'Content-Type'
:
'application/x-www-form-urlencoded; charset=UTF-8'
,
'X-Naver-Client-Id'
:
`
${
PAPAGO_ID
}
`
,
'X-Naver-Client-Secret'
:
`
${
PAPAGO_SECRET
}
`
},
body
:
'source=ko&target=en&text='
+
message
,
json
:
true
},(
error
,
response
,
body
)
=>
{
if
(
!
error
&&
response
.
statusCode
==
200
)
{
console
.
log
(
body
.
message
);
var
transMessage
=
body
.
message
.
result
.
translatedText
;
request
.
post
(
{
url
:
TARGET_URL
,
headers
:
{
'Authorization'
:
`Bearer
${
TOKEN
}
`
},
json
:
{
"replyToken"
:
replyToken
,
"messages"
:[
{
"type"
:
"text"
,
"text"
:
transMessage
}
]
}
},(
error
,
response
,
body
)
=>
{
console
.
log
(
body
)
});
}
});
}
try
{
const
option
=
{
ca
:
fs
.
readFileSync
(
'/etc/letsencrypt/live/'
+
domain
+
'/fullchain.pem'
),
key
:
fs
.
readFileSync
(
path
.
resolve
(
process
.
cwd
(),
'/etc/letsencrypt/live/'
+
domain
+
'/privkey.pem'
),
'utf8'
).
toString
(),
cert
:
fs
.
readFileSync
(
path
.
resolve
(
process
.
cwd
(),
'/etc/letsencrypt/live/'
+
domain
+
'/cert.pem'
),
'utf8'
).
toString
(),
};
HTTPS
.
createServer
(
option
,
app
).
listen
(
sslport
,
()
=>
{
console
.
log
(
`[HTTPS] Server is started on port
${
sslport
}
`
);
});
}
catch
(
error
)
{
console
.
log
(
'[HTTPS] HTTPS 오류가 발생하였습니다. HTTPS 서버는 실행되지 않습니다.'
);
console
.
log
(
error
);
}
\ No newline at end of file
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/messenger/trans/package-lock.json
0 → 100644
View file @
9fa45f8
{
"name"
:
"trans"
,
"version"
:
"1.0.0"
,
"lockfileVersion"
:
1
,
"requires"
:
true
,
"dependencies"
:
{
"accepts"
:
{
"version"
:
"1.3.7"
,
"resolved"
:
"https://registry.npmjs.org/accepts/-/accepts-1.3.7.tgz"
,
"integrity"
:
"sha512-Il80Qs2WjYlJIBNzNkK6KYqlVMTbZLXgHx2oT0pU/fjRHyEp+PEfEPY0R3WCwAGVOtauxh1hOxNgIf5bv7dQpA=="
,
"requires"
:
{
"mime-types"
:
"~2.1.24"
,
"negotiator"
:
"0.6.2"
}
},
"ajv"
:
{
"version"
:
"6.12.2"
,
"resolved"
:
"https://registry.npmjs.org/ajv/-/ajv-6.12.2.tgz"
,
"integrity"
:
"sha512-k+V+hzjm5q/Mr8ef/1Y9goCmlsK4I6Sm74teeyGvFk1XrOsbsKLjEdrvny42CZ+a8sXbk8KWpY/bDwS+FLL2UQ=="
,
"requires"
:
{
"fast-deep-equal"
:
"^3.1.1"
,
"fast-json-stable-stringify"
:
"^2.0.0"
,
"json-schema-traverse"
:
"^0.4.1"
,
"uri-js"
:
"^4.2.2"
}
},
"array-flatten"
:
{
"version"
:
"1.1.1"
,
"resolved"
:
"https://registry.npmjs.org/array-flatten/-/array-flatten-1.1.1.tgz"
,
"integrity"
:
"sha1-ml9pkFGx5wczKPKgCJaLZOopVdI="
},
"asn1"
:
{
"version"
:
"0.2.4"
,
"resolved"
:
"https://registry.npmjs.org/asn1/-/asn1-0.2.4.tgz"
,
"integrity"
:
"sha512-jxwzQpLQjSmWXgwaCZE9Nz+glAG01yF1QnWgbhGwHI5A6FRIEY6IVqtHhIepHqI7/kyEyQEagBC5mBEFlIYvdg=="
,
"requires"
:
{
"safer-buffer"
:
"~2.1.0"
}
},
"assert-plus"
:
{
"version"
:
"1.0.0"
,
"resolved"
:
"https://registry.npmjs.org/assert-plus/-/assert-plus-1.0.0.tgz"
,
"integrity"
:
"sha1-8S4PPF13sLHN2RRpQuTpbB5N1SU="
},
"asynckit"
:
{
"version"
:
"0.4.0"
,
"resolved"
:
"https://registry.npmjs.org/asynckit/-/asynckit-0.4.0.tgz"
,
"integrity"
:
"sha1-x57Zf380y48robyXkLzDZkdLS3k="
},
"aws-sign2"
:
{
"version"
:
"0.7.0"
,
"resolved"
:
"https://registry.npmjs.org/aws-sign2/-/aws-sign2-0.7.0.tgz"
,
"integrity"
:
"sha1-tG6JCTSpWR8tL2+G1+ap8bP+dqg="
},
"aws4"
:
{
"version"
:
"1.9.1"
,
"resolved"
:
"https://registry.npmjs.org/aws4/-/aws4-1.9.1.tgz"
,
"integrity"
:
"sha512-wMHVg2EOHaMRxbzgFJ9gtjOOCrI80OHLG14rxi28XwOW8ux6IiEbRCGGGqCtdAIg4FQCbW20k9RsT4y3gJlFug=="
},
"bcrypt-pbkdf"
:
{
"version"
:
"1.0.2"
,
"resolved"
:
"https://registry.npmjs.org/bcrypt-pbkdf/-/bcrypt-pbkdf-1.0.2.tgz"
,
"integrity"
:
"sha1-pDAdOJtqQ/m2f/PKEaP2Y342Dp4="
,
"requires"
:
{
"tweetnacl"
:
"^0.14.3"
}
},
"body-parser"
:
{
"version"
:
"1.19.0"
,
"resolved"
:
"https://registry.npmjs.org/body-parser/-/body-parser-1.19.0.tgz"
,
"integrity"
:
"sha512-dhEPs72UPbDnAQJ9ZKMNTP6ptJaionhP5cBb541nXPlW60Jepo9RV/a4fX4XWW9CuFNK22krhrj1+rgzifNCsw=="
,
"requires"
:
{
"bytes"
:
"3.1.0"
,
"content-type"
:
"~1.0.4"
,
"debug"
:
"2.6.9"
,
"depd"
:
"~1.1.2"
,
"http-errors"
:
"1.7.2"
,
"iconv-lite"
:
"0.4.24"
,
"on-finished"
:
"~2.3.0"
,
"qs"
:
"6.7.0"
,
"raw-body"
:
"2.4.0"
,
"type-is"
:
"~1.6.17"
}
},
"bytes"
:
{
"version"
:
"3.1.0"
,
"resolved"
:
"https://registry.npmjs.org/bytes/-/bytes-3.1.0.tgz"
,
"integrity"
:
"sha512-zauLjrfCG+xvoyaqLoV8bLVXXNGC4JqlxFCutSDWA6fJrTo2ZuvLYTqZ7aHBLZSMOopbzwv8f+wZcVzfVTI2Dg=="
},
"caseless"
:
{
"version"
:
"0.12.0"
,
"resolved"
:
"https://registry.npmjs.org/caseless/-/caseless-0.12.0.tgz"
,
"integrity"
:
"sha1-G2gcIf+EAzyCZUMJBolCDRhxUdw="
},
"combined-stream"
:
{
"version"
:
"1.0.8"
,
"resolved"
:
"https://registry.npmjs.org/combined-stream/-/combined-stream-1.0.8.tgz"
,
"integrity"
:
"sha512-FQN4MRfuJeHf7cBbBMJFXhKSDq+2kAArBlmRBvcvFE5BB1HZKXtSFASDhdlz9zOYwxh8lDdnvmMOe/+5cdoEdg=="
,
"requires"
:
{
"delayed-stream"
:
"~1.0.0"
}
},
"content-disposition"
:
{
"version"
:
"0.5.3"
,
"resolved"
:
"https://registry.npmjs.org/content-disposition/-/content-disposition-0.5.3.tgz"
,
"integrity"
:
"sha512-ExO0774ikEObIAEV9kDo50o+79VCUdEB6n6lzKgGwupcVeRlhrj3qGAfwq8G6uBJjkqLrhT0qEYFcWng8z1z0g=="
,
"requires"
:
{
"safe-buffer"
:
"5.1.2"
}
},
"content-type"
:
{
"version"
:
"1.0.4"
,
"resolved"
:
"https://registry.npmjs.org/content-type/-/content-type-1.0.4.tgz"
,
"integrity"
:
"sha512-hIP3EEPs8tB9AT1L+NUqtwOAps4mk2Zob89MWXMHjHWg9milF/j4osnnQLXBCBFBk/tvIG/tUc9mOUJiPBhPXA=="
},
"cookie"
:
{
"version"
:
"0.4.0"
,
"resolved"
:
"https://registry.npmjs.org/cookie/-/cookie-0.4.0.tgz"
,
"integrity"
:
"sha512-+Hp8fLp57wnUSt0tY0tHEXh4voZRDnoIrZPqlo3DPiI4y9lwg/jqx+1Om94/W6ZaPDOUbnjOt/99w66zk+l1Xg=="
},
"cookie-signature"
:
{
"version"
:
"1.0.6"
,
"resolved"
:
"https://registry.npmjs.org/cookie-signature/-/cookie-signature-1.0.6.tgz"
,
"integrity"
:
"sha1-4wOogrNCzD7oylE6eZmXNNqzriw="
},
"core-util-is"
:
{
"version"
:
"1.0.2"
,
"resolved"
:
"https://registry.npmjs.org/core-util-is/-/core-util-is-1.0.2.tgz"
,
"integrity"
:
"sha1-tf1UIgqivFq1eqtxQMlAdUUDwac="
},
"dashdash"
:
{
"version"
:
"1.14.1"
,
"resolved"
:
"https://registry.npmjs.org/dashdash/-/dashdash-1.14.1.tgz"
,
"integrity"
:
"sha1-hTz6D3y+L+1d4gMmuN1YEDX24vA="
,
"requires"
:
{
"assert-plus"
:
"^1.0.0"
}
},
"debug"
:
{
"version"
:
"2.6.9"
,
"resolved"
:
"https://registry.npmjs.org/debug/-/debug-2.6.9.tgz"
,
"integrity"
:
"sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA=="
,
"requires"
:
{
"ms"
:
"2.0.0"
}
},
"delayed-stream"
:
{
"version"
:
"1.0.0"
,
"resolved"
:
"https://registry.npmjs.org/delayed-stream/-/delayed-stream-1.0.0.tgz"
,
"integrity"
:
"sha1-3zrhmayt+31ECqrgsp4icrJOxhk="
},
"depd"
:
{
"version"
:
"1.1.2"
,
"resolved"
:
"https://registry.npmjs.org/depd/-/depd-1.1.2.tgz"
,
"integrity"
:
"sha1-m81S4UwJd2PnSbJ0xDRu0uVgtak="
},
"destroy"
:
{
"version"
:
"1.0.4"
,
"resolved"
:
"https://registry.npmjs.org/destroy/-/destroy-1.0.4.tgz"
,
"integrity"
:
"sha1-l4hXRCxEdJ5CBmE+N5RiBYJqvYA="
},
"ecc-jsbn"
:
{
"version"
:
"0.1.2"
,
"resolved"
:
"https://registry.npmjs.org/ecc-jsbn/-/ecc-jsbn-0.1.2.tgz"
,
"integrity"
:
"sha1-OoOpBOVDUyh4dMVkt1SThoSamMk="
,
"requires"
:
{
"jsbn"
:
"~0.1.0"
,
"safer-buffer"
:
"^2.1.0"
}
},
"ee-first"
:
{
"version"
:
"1.1.1"
,
"resolved"
:
"https://registry.npmjs.org/ee-first/-/ee-first-1.1.1.tgz"
,
"integrity"
:
"sha1-WQxhFWsK4vTwJVcyoViyZrxWsh0="
},
"encodeurl"
:
{
"version"
:
"1.0.2"
,
"resolved"
:
"https://registry.npmjs.org/encodeurl/-/encodeurl-1.0.2.tgz"
,
"integrity"
:
"sha1-rT/0yG7C0CkyL1oCw6mmBslbP1k="
},
"escape-html"
:
{
"version"
:
"1.0.3"
,
"resolved"
:
"https://registry.npmjs.org/escape-html/-/escape-html-1.0.3.tgz"
,
"integrity"
:
"sha1-Aljq5NPQwJdN4cFpGI7wBR0dGYg="
},
"etag"
:
{
"version"
:
"1.8.1"
,
"resolved"
:
"https://registry.npmjs.org/etag/-/etag-1.8.1.tgz"
,
"integrity"
:
"sha1-Qa4u62XvpiJorr/qg6x9eSmbCIc="
},
"express"
:
{
"version"
:
"4.17.1"
,
"resolved"
:
"https://registry.npmjs.org/express/-/express-4.17.1.tgz"
,
"integrity"
:
"sha512-mHJ9O79RqluphRrcw2X/GTh3k9tVv8YcoyY4Kkh4WDMUYKRZUq0h1o0w2rrrxBqM7VoeUVqgb27xlEMXTnYt4g=="
,
"requires"
:
{
"accepts"
:
"~1.3.7"
,
"array-flatten"
:
"1.1.1"
,
"body-parser"
:
"1.19.0"
,
"content-disposition"
:
"0.5.3"
,
"content-type"
:
"~1.0.4"
,
"cookie"
:
"0.4.0"
,
"cookie-signature"
:
"1.0.6"
,
"debug"
:
"2.6.9"
,
"depd"
:
"~1.1.2"
,
"encodeurl"
:
"~1.0.2"
,
"escape-html"
:
"~1.0.3"
,
"etag"
:
"~1.8.1"
,
"finalhandler"
:
"~1.1.2"
,
"fresh"
:
"0.5.2"
,
"merge-descriptors"
:
"1.0.1"
,
"methods"
:
"~1.1.2"
,
"on-finished"
:
"~2.3.0"
,
"parseurl"
:
"~1.3.3"
,
"path-to-regexp"
:
"0.1.7"
,
"proxy-addr"
:
"~2.0.5"
,
"qs"
:
"6.7.0"
,
"range-parser"
:
"~1.2.1"
,
"safe-buffer"
:
"5.1.2"
,
"send"
:
"0.17.1"
,
"serve-static"
:
"1.14.1"
,
"setprototypeof"
:
"1.1.1"
,
"statuses"
:
"~1.5.0"
,
"type-is"
:
"~1.6.18"
,
"utils-merge"
:
"1.0.1"
,
"vary"
:
"~1.1.2"
}
},
"extend"
:
{
"version"
:
"3.0.2"
,
"resolved"
:
"https://registry.npmjs.org/extend/-/extend-3.0.2.tgz"
,
"integrity"
:
"sha512-fjquC59cD7CyW6urNXK0FBufkZcoiGG80wTuPujX590cB5Ttln20E2UB4S/WARVqhXffZl2LNgS+gQdPIIim/g=="
},
"extsprintf"
:
{
"version"
:
"1.3.0"
,
"resolved"
:
"https://registry.npmjs.org/extsprintf/-/extsprintf-1.3.0.tgz"
,
"integrity"
:
"sha1-lpGEQOMEGnpBT4xS48V06zw+HgU="
},
"fast-deep-equal"
:
{
"version"
:
"3.1.1"
,
"resolved"
:
"https://registry.npmjs.org/fast-deep-equal/-/fast-deep-equal-3.1.1.tgz"
,
"integrity"
:
"sha512-8UEa58QDLauDNfpbrX55Q9jrGHThw2ZMdOky5Gl1CDtVeJDPVrG4Jxx1N8jw2gkWaff5UUuX1KJd+9zGe2B+ZA=="
},
"fast-json-stable-stringify"
:
{
"version"
:
"2.1.0"
,
"resolved"
:
"https://registry.npmjs.org/fast-json-stable-stringify/-/fast-json-stable-stringify-2.1.0.tgz"
,
"integrity"
:
"sha512-lhd/wF+Lk98HZoTCtlVraHtfh5XYijIjalXck7saUtuanSDyLMxnHhSXEDJqHxD7msR8D0uCmqlkwjCV8xvwHw=="
},
"finalhandler"
:
{
"version"
:
"1.1.2"
,
"resolved"
:
"https://registry.npmjs.org/finalhandler/-/finalhandler-1.1.2.tgz"
,
"integrity"
:
"sha512-aAWcW57uxVNrQZqFXjITpW3sIUQmHGG3qSb9mUah9MgMC4NeWhNOlNjXEYq3HjRAvL6arUviZGGJsBg6z0zsWA=="
,
"requires"
:
{
"debug"
:
"2.6.9"
,
"encodeurl"
:
"~1.0.2"
,
"escape-html"
:
"~1.0.3"
,
"on-finished"
:
"~2.3.0"
,
"parseurl"
:
"~1.3.3"
,
"statuses"
:
"~1.5.0"
,
"unpipe"
:
"~1.0.0"
}
},
"forever-agent"
:
{
"version"
:
"0.6.1"
,
"resolved"
:
"https://registry.npmjs.org/forever-agent/-/forever-agent-0.6.1.tgz"
,
"integrity"
:
"sha1-+8cfDEGt6zf5bFd60e1C2P2sypE="
},
"form-data"
:
{
"version"
:
"2.3.3"
,
"resolved"
:
"https://registry.npmjs.org/form-data/-/form-data-2.3.3.tgz"
,
"integrity"
:
"sha512-1lLKB2Mu3aGP1Q/2eCOx0fNbRMe7XdwktwOruhfqqd0rIJWwN4Dh+E3hrPSlDCXnSR7UtZ1N38rVXm+6+MEhJQ=="
,
"requires"
:
{
"asynckit"
:
"^0.4.0"
,
"combined-stream"
:
"^1.0.6"
,
"mime-types"
:
"^2.1.12"
}
},
"forwarded"
:
{
"version"
:
"0.1.2"
,
"resolved"
:
"https://registry.npmjs.org/forwarded/-/forwarded-0.1.2.tgz"
,
"integrity"
:
"sha1-mMI9qxF1ZXuMBXPozszZGw/xjIQ="
},
"fresh"
:
{
"version"
:
"0.5.2"
,
"resolved"
:
"https://registry.npmjs.org/fresh/-/fresh-0.5.2.tgz"
,
"integrity"
:
"sha1-PYyt2Q2XZWn6g1qx+OSyOhBWBac="
},
"getpass"
:
{
"version"
:
"0.1.7"
,
"resolved"
:
"https://registry.npmjs.org/getpass/-/getpass-0.1.7.tgz"
,
"integrity"
:
"sha1-Xv+OPmhNVprkyysSgmBOi6YhSfo="
,
"requires"
:
{
"assert-plus"
:
"^1.0.0"
}
},
"har-schema"
:
{
"version"
:
"2.0.0"
,
"resolved"
:
"https://registry.npmjs.org/har-schema/-/har-schema-2.0.0.tgz"
,
"integrity"
:
"sha1-qUwiJOvKwEeCoNkDVSHyRzW37JI="
},
"har-validator"
:
{
"version"
:
"5.1.3"
,
"resolved"
:
"https://registry.npmjs.org/har-validator/-/har-validator-5.1.3.tgz"
,
"integrity"
:
"sha512-sNvOCzEQNr/qrvJgc3UG/kD4QtlHycrzwS+6mfTrrSq97BvaYcPZZI1ZSqGSPR73Cxn4LKTD4PttRwfU7jWq5g=="
,
"requires"
:
{
"ajv"
:
"^6.5.5"
,
"har-schema"
:
"^2.0.0"
}
},
"http-errors"
:
{
"version"
:
"1.7.2"
,
"resolved"
:
"https://registry.npmjs.org/http-errors/-/http-errors-1.7.2.tgz"
,
"integrity"
:
"sha512-uUQBt3H/cSIVfch6i1EuPNy/YsRSOUBXTVfZ+yR7Zjez3qjBz6i9+i4zjNaoqcoFVI4lQJ5plg63TvGfRSDCRg=="
,
"requires"
:
{
"depd"
:
"~1.1.2"
,
"inherits"
:
"2.0.3"
,
"setprototypeof"
:
"1.1.1"
,
"statuses"
:
">= 1.5.0 < 2"
,
"toidentifier"
:
"1.0.0"
}
},
"http-signature"
:
{
"version"
:
"1.2.0"
,
"resolved"
:
"https://registry.npmjs.org/http-signature/-/http-signature-1.2.0.tgz"
,
"integrity"
:
"sha1-muzZJRFHcvPZW2WmCruPfBj7rOE="
,
"requires"
:
{
"assert-plus"
:
"^1.0.0"
,
"jsprim"
:
"^1.2.2"
,
"sshpk"
:
"^1.7.0"
}
},
"iconv-lite"
:
{
"version"
:
"0.4.24"
,
"resolved"
:
"https://registry.npmjs.org/iconv-lite/-/iconv-lite-0.4.24.tgz"
,
"integrity"
:
"sha512-v3MXnZAcvnywkTUEZomIActle7RXXeedOR31wwl7VlyoXO4Qi9arvSenNQWne1TcRwhCL1HwLI21bEqdpj8/rA=="
,
"requires"
:
{
"safer-buffer"
:
">= 2.1.2 < 3"
}
},
"inherits"
:
{
"version"
:
"2.0.3"
,
"resolved"
:
"https://registry.npmjs.org/inherits/-/inherits-2.0.3.tgz"
,
"integrity"
:
"sha1-Yzwsg+PaQqUC9SRmAiSA9CCCYd4="
},
"ipaddr.js"
:
{
"version"
:
"1.9.1"
,
"resolved"
:
"https://registry.npmjs.org/ipaddr.js/-/ipaddr.js-1.9.1.tgz"
,
"integrity"
:
"sha512-0KI/607xoxSToH7GjN1FfSbLoU0+btTicjsQSWQlh/hZykN8KpmMf7uYwPW3R+akZ6R/w18ZlXSHBYXiYUPO3g=="
},
"is-typedarray"
:
{
"version"
:
"1.0.0"
,
"resolved"
:
"https://registry.npmjs.org/is-typedarray/-/is-typedarray-1.0.0.tgz"
,
"integrity"
:
"sha1-5HnICFjfDBsR3dppQPlgEfzaSpo="
},
"isstream"
:
{
"version"
:
"0.1.2"
,
"resolved"
:
"https://registry.npmjs.org/isstream/-/isstream-0.1.2.tgz"
,
"integrity"
:
"sha1-R+Y/evVa+m+S4VAOaQ64uFKcCZo="
},
"jsbn"
:
{
"version"
:
"0.1.1"
,
"resolved"
:
"https://registry.npmjs.org/jsbn/-/jsbn-0.1.1.tgz"
,
"integrity"
:
"sha1-peZUwuWi3rXyAdls77yoDA7y9RM="
},
"json-schema"
:
{
"version"
:
"0.2.3"
,
"resolved"
:
"https://registry.npmjs.org/json-schema/-/json-schema-0.2.3.tgz"
,
"integrity"
:
"sha1-tIDIkuWaLwWVTOcnvT8qTogvnhM="
},
"json-schema-traverse"
:
{
"version"
:
"0.4.1"
,
"resolved"
:
"https://registry.npmjs.org/json-schema-traverse/-/json-schema-traverse-0.4.1.tgz"
,
"integrity"
:
"sha512-xbbCH5dCYU5T8LcEhhuh7HJ88HXuW3qsI3Y0zOZFKfZEHcpWiHU/Jxzk629Brsab/mMiHQti9wMP+845RPe3Vg=="
},
"json-stringify-safe"
:
{
"version"
:
"5.0.1"
,
"resolved"
:
"https://registry.npmjs.org/json-stringify-safe/-/json-stringify-safe-5.0.1.tgz"
,
"integrity"
:
"sha1-Epai1Y/UXxmg9s4B1lcB4sc1tus="
},
"jsprim"
:
{
"version"
:
"1.4.1"
,
"resolved"
:
"https://registry.npmjs.org/jsprim/-/jsprim-1.4.1.tgz"
,
"integrity"
:
"sha1-MT5mvB5cwG5Di8G3SZwuXFastqI="
,
"requires"
:
{
"assert-plus"
:
"1.0.0"
,
"extsprintf"
:
"1.3.0"
,
"json-schema"
:
"0.2.3"
,
"verror"
:
"1.10.0"
}
},
"media-typer"
:
{
"version"
:
"0.3.0"
,
"resolved"
:
"https://registry.npmjs.org/media-typer/-/media-typer-0.3.0.tgz"
,
"integrity"
:
"sha1-hxDXrwqmJvj/+hzgAWhUUmMlV0g="
},
"merge-descriptors"
:
{
"version"
:
"1.0.1"
,
"resolved"
:
"https://registry.npmjs.org/merge-descriptors/-/merge-descriptors-1.0.1.tgz"
,
"integrity"
:
"sha1-sAqqVW3YtEVoFQ7J0blT8/kMu2E="
},
"methods"
:
{
"version"
:
"1.1.2"
,
"resolved"
:
"https://registry.npmjs.org/methods/-/methods-1.1.2.tgz"
,
"integrity"
:
"sha1-VSmk1nZUE07cxSZmVoNbD4Ua/O4="
},
"mime"
:
{
"version"
:
"1.6.0"
,
"resolved"
:
"https://registry.npmjs.org/mime/-/mime-1.6.0.tgz"
,
"integrity"
:
"sha512-x0Vn8spI+wuJ1O6S7gnbaQg8Pxh4NNHb7KSINmEWKiPE4RKOplvijn+NkmYmmRgP68mc70j2EbeTFRsrswaQeg=="
},
"mime-db"
:
{
"version"
:
"1.44.0"
,
"resolved"
:
"https://registry.npmjs.org/mime-db/-/mime-db-1.44.0.tgz"
,
"integrity"
:
"sha512-/NOTfLrsPBVeH7YtFPgsVWveuL+4SjjYxaQ1xtM1KMFj7HdxlBlxeyNLzhyJVx7r4rZGJAZ/6lkKCitSc/Nmpg=="
},
"mime-types"
:
{
"version"
:
"2.1.27"
,
"resolved"
:
"https://registry.npmjs.org/mime-types/-/mime-types-2.1.27.tgz"
,
"integrity"
:
"sha512-JIhqnCasI9yD+SsmkquHBxTSEuZdQX5BuQnS2Vc7puQQQ+8yiP5AY5uWhpdv4YL4VM5c6iliiYWPgJ/nJQLp7w=="
,
"requires"
:
{
"mime-db"
:
"1.44.0"
}
},
"ms"
:
{
"version"
:
"2.0.0"
,
"resolved"
:
"https://registry.npmjs.org/ms/-/ms-2.0.0.tgz"
,
"integrity"
:
"sha1-VgiurfwAvmwpAd9fmGF4jeDVl8g="
},
"negotiator"
:
{
"version"
:
"0.6.2"
,
"resolved"
:
"https://registry.npmjs.org/negotiator/-/negotiator-0.6.2.tgz"
,
"integrity"
:
"sha512-hZXc7K2e+PgeI1eDBe/10Ard4ekbfrrqG8Ep+8Jmf4JID2bNg7NvCPOZN+kfF574pFQI7mum2AUqDidoKqcTOw=="
},
"oauth-sign"
:
{
"version"
:
"0.9.0"
,
"resolved"
:
"https://registry.npmjs.org/oauth-sign/-/oauth-sign-0.9.0.tgz"
,
"integrity"
:
"sha512-fexhUFFPTGV8ybAtSIGbV6gOkSv8UtRbDBnAyLQw4QPKkgNlsH2ByPGtMUqdWkos6YCRmAqViwgZrJc/mRDzZQ=="
},
"on-finished"
:
{
"version"
:
"2.3.0"
,
"resolved"
:
"https://registry.npmjs.org/on-finished/-/on-finished-2.3.0.tgz"
,
"integrity"
:
"sha1-IPEzZIGwg811M3mSoWlxqi2QaUc="
,
"requires"
:
{
"ee-first"
:
"1.1.1"
}
},
"parseurl"
:
{
"version"
:
"1.3.3"
,
"resolved"
:
"https://registry.npmjs.org/parseurl/-/parseurl-1.3.3.tgz"
,
"integrity"
:
"sha512-CiyeOxFT/JZyN5m0z9PfXw4SCBJ6Sygz1Dpl0wqjlhDEGGBP1GnsUVEL0p63hoG1fcj3fHynXi9NYO4nWOL+qQ=="
},
"path-to-regexp"
:
{
"version"
:
"0.1.7"
,
"resolved"
:
"https://registry.npmjs.org/path-to-regexp/-/path-to-regexp-0.1.7.tgz"
,
"integrity"
:
"sha1-32BBeABfUi8V60SQ5yR6G/qmf4w="
},
"performance-now"
:
{
"version"
:
"2.1.0"
,
"resolved"
:
"https://registry.npmjs.org/performance-now/-/performance-now-2.1.0.tgz"
,
"integrity"
:
"sha1-Ywn04OX6kT7BxpMHrjZLSzd8nns="
},
"proxy-addr"
:
{
"version"
:
"2.0.6"
,
"resolved"
:
"https://registry.npmjs.org/proxy-addr/-/proxy-addr-2.0.6.tgz"
,
"integrity"
:
"sha512-dh/frvCBVmSsDYzw6n926jv974gddhkFPfiN8hPOi30Wax25QZyZEGveluCgliBnqmuM+UJmBErbAUFIoDbjOw=="
,
"requires"
:
{
"forwarded"
:
"~0.1.2"
,
"ipaddr.js"
:
"1.9.1"
}
},
"psl"
:
{
"version"
:
"1.8.0"
,
"resolved"
:
"https://registry.npmjs.org/psl/-/psl-1.8.0.tgz"
,
"integrity"
:
"sha512-RIdOzyoavK+hA18OGGWDqUTsCLhtA7IcZ/6NCs4fFJaHBDab+pDDmDIByWFRQJq2Cd7r1OoQxBGKOaztq+hjIQ=="
},
"punycode"
:
{
"version"
:
"2.1.1"
,
"resolved"
:
"https://registry.npmjs.org/punycode/-/punycode-2.1.1.tgz"
,
"integrity"
:
"sha512-XRsRjdf+j5ml+y/6GKHPZbrF/8p2Yga0JPtdqTIY2Xe5ohJPD9saDJJLPvp9+NSBprVvevdXZybnj2cv8OEd0A=="
},
"qs"
:
{
"version"
:
"6.7.0"
,
"resolved"
:
"https://registry.npmjs.org/qs/-/qs-6.7.0.tgz"
,
"integrity"
:
"sha512-VCdBRNFTX1fyE7Nb6FYoURo/SPe62QCaAyzJvUjwRaIsc+NePBEniHlvxFmmX56+HZphIGtV0XeCirBtpDrTyQ=="
},
"range-parser"
:
{
"version"
:
"1.2.1"
,
"resolved"
:
"https://registry.npmjs.org/range-parser/-/range-parser-1.2.1.tgz"
,
"integrity"
:
"sha512-Hrgsx+orqoygnmhFbKaHE6c296J+HTAQXoxEF6gNupROmmGJRoyzfG3ccAveqCBrwr/2yxQ5BVd/GTl5agOwSg=="
},
"raw-body"
:
{
"version"
:
"2.4.0"
,
"resolved"
:
"https://registry.npmjs.org/raw-body/-/raw-body-2.4.0.tgz"
,
"integrity"
:
"sha512-4Oz8DUIwdvoa5qMJelxipzi/iJIi40O5cGV1wNYp5hvZP8ZN0T+jiNkL0QepXs+EsQ9XJ8ipEDoiH70ySUJP3Q=="
,
"requires"
:
{
"bytes"
:
"3.1.0"
,
"http-errors"
:
"1.7.2"
,
"iconv-lite"
:
"0.4.24"
,
"unpipe"
:
"1.0.0"
}
},
"request"
:
{
"version"
:
"2.88.2"
,
"resolved"
:
"https://registry.npmjs.org/request/-/request-2.88.2.tgz"
,
"integrity"
:
"sha512-MsvtOrfG9ZcrOwAW+Qi+F6HbD0CWXEh9ou77uOb7FM2WPhwT7smM833PzanhJLsgXjN89Ir6V2PczXNnMpwKhw=="
,
"requires"
:
{
"aws-sign2"
:
"~0.7.0"
,
"aws4"
:
"^1.8.0"
,
"caseless"
:
"~0.12.0"
,
"combined-stream"
:
"~1.0.6"
,
"extend"
:
"~3.0.2"
,
"forever-agent"
:
"~0.6.1"
,
"form-data"
:
"~2.3.2"
,
"har-validator"
:
"~5.1.3"
,
"http-signature"
:
"~1.2.0"
,
"is-typedarray"
:
"~1.0.0"
,
"isstream"
:
"~0.1.2"
,
"json-stringify-safe"
:
"~5.0.1"
,
"mime-types"
:
"~2.1.19"
,
"oauth-sign"
:
"~0.9.0"
,
"performance-now"
:
"^2.1.0"
,
"qs"
:
"~6.5.2"
,
"safe-buffer"
:
"^5.1.2"
,
"tough-cookie"
:
"~2.5.0"
,
"tunnel-agent"
:
"^0.6.0"
,
"uuid"
:
"^3.3.2"
},
"dependencies"
:
{
"qs"
:
{
"version"
:
"6.5.2"
,
"resolved"
:
"https://registry.npmjs.org/qs/-/qs-6.5.2.tgz"
,
"integrity"
:
"sha512-N5ZAX4/LxJmF+7wN74pUD6qAh9/wnvdQcjq9TZjevvXzSUo7bfmw91saqMjzGS2xq91/odN2dW/WOl7qQHNDGA=="
}
}
},
"safe-buffer"
:
{
"version"
:
"5.1.2"
,
"resolved"
:
"https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.1.2.tgz"
,
"integrity"
:
"sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g=="
},
"safer-buffer"
:
{
"version"
:
"2.1.2"
,
"resolved"
:
"https://registry.npmjs.org/safer-buffer/-/safer-buffer-2.1.2.tgz"
,
"integrity"
:
"sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg=="
},
"send"
:
{
"version"
:
"0.17.1"
,
"resolved"
:
"https://registry.npmjs.org/send/-/send-0.17.1.tgz"
,
"integrity"
:
"sha512-BsVKsiGcQMFwT8UxypobUKyv7irCNRHk1T0G680vk88yf6LBByGcZJOTJCrTP2xVN6yI+XjPJcNuE3V4fT9sAg=="
,
"requires"
:
{
"debug"
:
"2.6.9"
,
"depd"
:
"~1.1.2"
,
"destroy"
:
"~1.0.4"
,
"encodeurl"
:
"~1.0.2"
,
"escape-html"
:
"~1.0.3"
,
"etag"
:
"~1.8.1"
,
"fresh"
:
"0.5.2"
,
"http-errors"
:
"~1.7.2"
,
"mime"
:
"1.6.0"
,
"ms"
:
"2.1.1"
,
"on-finished"
:
"~2.3.0"
,
"range-parser"
:
"~1.2.1"
,
"statuses"
:
"~1.5.0"
},
"dependencies"
:
{
"ms"
:
{
"version"
:
"2.1.1"
,
"resolved"
:
"https://registry.npmjs.org/ms/-/ms-2.1.1.tgz"
,
"integrity"
:
"sha512-tgp+dl5cGk28utYktBsrFqA7HKgrhgPsg6Z/EfhWI4gl1Hwq8B/GmY/0oXZ6nF8hDVesS/FpnYaD/kOWhYQvyg=="
}
}
},
"serve-static"
:
{
"version"
:
"1.14.1"
,
"resolved"
:
"https://registry.npmjs.org/serve-static/-/serve-static-1.14.1.tgz"
,
"integrity"
:
"sha512-JMrvUwE54emCYWlTI+hGrGv5I8dEwmco/00EvkzIIsR7MqrHonbD9pO2MOfFnpFntl7ecpZs+3mW+XbQZu9QCg=="
,
"requires"
:
{
"encodeurl"
:
"~1.0.2"
,
"escape-html"
:
"~1.0.3"
,
"parseurl"
:
"~1.3.3"
,
"send"
:
"0.17.1"
}
},
"setprototypeof"
:
{
"version"
:
"1.1.1"
,
"resolved"
:
"https://registry.npmjs.org/setprototypeof/-/setprototypeof-1.1.1.tgz"
,
"integrity"
:
"sha512-JvdAWfbXeIGaZ9cILp38HntZSFSo3mWg6xGcJJsd+d4aRMOqauag1C63dJfDw7OaMYwEbHMOxEZ1lqVRYP2OAw=="
},
"sshpk"
:
{
"version"
:
"1.16.1"
,
"resolved"
:
"https://registry.npmjs.org/sshpk/-/sshpk-1.16.1.tgz"
,
"integrity"
:
"sha512-HXXqVUq7+pcKeLqqZj6mHFUMvXtOJt1uoUx09pFW6011inTMxqI8BA8PM95myrIyyKwdnzjdFjLiE6KBPVtJIg=="
,
"requires"
:
{
"asn1"
:
"~0.2.3"
,
"assert-plus"
:
"^1.0.0"
,
"bcrypt-pbkdf"
:
"^1.0.0"
,
"dashdash"
:
"^1.12.0"
,
"ecc-jsbn"
:
"~0.1.1"
,
"getpass"
:
"^0.1.1"
,
"jsbn"
:
"~0.1.0"
,
"safer-buffer"
:
"^2.0.2"
,
"tweetnacl"
:
"~0.14.0"
}
},
"statuses"
:
{
"version"
:
"1.5.0"
,
"resolved"
:
"https://registry.npmjs.org/statuses/-/statuses-1.5.0.tgz"
,
"integrity"
:
"sha1-Fhx9rBd2Wf2YEfQ3cfqZOBR4Yow="
},
"toidentifier"
:
{
"version"
:
"1.0.0"
,
"resolved"
:
"https://registry.npmjs.org/toidentifier/-/toidentifier-1.0.0.tgz"
,
"integrity"
:
"sha512-yaOH/Pk/VEhBWWTlhI+qXxDFXlejDGcQipMlyxda9nthulaxLZUNcUqFxokp0vcYnvteJln5FNQDRrxj3YcbVw=="
},
"tough-cookie"
:
{
"version"
:
"2.5.0"
,
"resolved"
:
"https://registry.npmjs.org/tough-cookie/-/tough-cookie-2.5.0.tgz"
,
"integrity"
:
"sha512-nlLsUzgm1kfLXSXfRZMc1KLAugd4hqJHDTvc2hDIwS3mZAfMEuMbc03SujMF+GEcpaX/qboeycw6iO8JwVv2+g=="
,
"requires"
:
{
"psl"
:
"^1.1.28"
,
"punycode"
:
"^2.1.1"
}
},
"tunnel-agent"
:
{
"version"
:
"0.6.0"
,
"resolved"
:
"https://registry.npmjs.org/tunnel-agent/-/tunnel-agent-0.6.0.tgz"
,
"integrity"
:
"sha1-J6XeoGs2sEoKmWZ3SykIaPD8QP0="
,
"requires"
:
{
"safe-buffer"
:
"^5.0.1"
}
},
"tweetnacl"
:
{
"version"
:
"0.14.5"
,
"resolved"
:
"https://registry.npmjs.org/tweetnacl/-/tweetnacl-0.14.5.tgz"
,
"integrity"
:
"sha1-WuaBd/GS1EViadEIr6k/+HQ/T2Q="
},
"type-is"
:
{
"version"
:
"1.6.18"
,
"resolved"
:
"https://registry.npmjs.org/type-is/-/type-is-1.6.18.tgz"
,
"integrity"
:
"sha512-TkRKr9sUTxEH8MdfuCSP7VizJyzRNMjj2J2do2Jr3Kym598JVdEksuzPQCnlFPW4ky9Q+iA+ma9BGm06XQBy8g=="
,
"requires"
:
{
"media-typer"
:
"0.3.0"
,
"mime-types"
:
"~2.1.24"
}
},
"unpipe"
:
{
"version"
:
"1.0.0"
,
"resolved"
:
"https://registry.npmjs.org/unpipe/-/unpipe-1.0.0.tgz"
,
"integrity"
:
"sha1-sr9O6FFKrmFltIF4KdIbLvSZBOw="
},
"uri-js"
:
{
"version"
:
"4.2.2"
,
"resolved"
:
"https://registry.npmjs.org/uri-js/-/uri-js-4.2.2.tgz"
,
"integrity"
:
"sha512-KY9Frmirql91X2Qgjry0Wd4Y+YTdrdZheS8TFwvkbLWf/G5KNJDCh6pKL5OZctEW4+0Baa5idK2ZQuELRwPznQ=="
,
"requires"
:
{
"punycode"
:
"^2.1.0"
}
},
"utils-merge"
:
{
"version"
:
"1.0.1"
,
"resolved"
:
"https://registry.npmjs.org/utils-merge/-/utils-merge-1.0.1.tgz"
,
"integrity"
:
"sha1-n5VxD1CiZ5R7LMwSR0HBAoQn5xM="
},
"uuid"
:
{
"version"
:
"3.4.0"
,
"resolved"
:
"https://registry.npmjs.org/uuid/-/uuid-3.4.0.tgz"
,
"integrity"
:
"sha512-HjSDRw6gZE5JMggctHBcjVak08+KEVhSIiDzFnT9S9aegmp85S/bReBVTb4QTFaRNptJ9kuYaNhnbNEOkbKb/A=="
},
"vary"
:
{
"version"
:
"1.1.2"
,
"resolved"
:
"https://registry.npmjs.org/vary/-/vary-1.1.2.tgz"
,
"integrity"
:
"sha1-IpnwLG3tMNSllhsLn3RSShj2NPw="
},
"verror"
:
{
"version"
:
"1.10.0"
,
"resolved"
:
"https://registry.npmjs.org/verror/-/verror-1.10.0.tgz"
,
"integrity"
:
"sha1-OhBcoXBTr1XW4nDB+CiGguGNpAA="
,
"requires"
:
{
"assert-plus"
:
"^1.0.0"
,
"core-util-is"
:
"1.0.2"
,
"extsprintf"
:
"^1.2.0"
}
}
}
}
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/messenger/trans/package.json
0 → 100644
View file @
9fa45f8
{
"name"
:
"trans"
,
"version"
:
"1.0.0"
,
"description"
:
""
,
"main"
:
"app.js"
,
"scripts"
:
{
"test"
:
"echo
\"
Error: no test specified
\"
&& exit 1"
},
"author"
:
""
,
"license"
:
"ISC"
,
"dependencies"
:
{
"express"
:
"^4.17.1"
,
"request"
:
"^2.88.2"
}
}
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/messenger/webhook/app.js
0 → 100644
View file @
9fa45f8
var
express
=
require
(
'express'
);
const
bodyParser
=
require
(
'body-parser'
);
var
app
=
express
();
const
fs
=
require
(
'fs'
);
const
path
=
require
(
'path'
);
const
HTTPS
=
require
(
'https'
);
const
domain
=
"도메인 변경 처리"
const
sslport
=
23023
;
app
.
use
(
bodyParser
.
json
());
app
.
post
(
'/hook'
,
function
(
request
,
response
)
{
var
eventObj
=
request
.
body
.
events
[
0
];
// request log
console
.
log
(
'======================'
,
new
Date
()
,
'======================'
);
response
.
sendStatus
(
200
);
});
try
{
const
option
=
{
ca
:
fs
.
readFileSync
(
'/etc/letsencrypt/live/'
+
domain
+
'/fullchain.pem'
),
key
:
fs
.
readFileSync
(
path
.
resolve
(
process
.
cwd
(),
'/etc/letsencrypt/live/'
+
domain
+
'/privkey.pem'
),
'utf8'
).
toString
(),
cert
:
fs
.
readFileSync
(
path
.
resolve
(
process
.
cwd
(),
'/etc/letsencrypt/live/'
+
domain
+
'/cert.pem'
),
'utf8'
).
toString
(),
};
HTTPS
.
createServer
(
option
,
app
).
listen
(
sslport
,
()
=>
{
console
.
log
(
`[HTTPS] Server is started on port
${
sslport
}
`
);
});
}
catch
(
error
)
{
console
.
log
(
'[HTTPS] HTTPS 오류가 발생하였습니다. HTTPS 서버는 실행되지 않습니다.'
);
console
.
log
(
error
);
}
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/messenger/webhook/package-lock.json
0 → 100644
View file @
9fa45f8
{
"name"
:
"webhook"
,
"version"
:
"1.0.0"
,
"lockfileVersion"
:
1
,
"requires"
:
true
,
"dependencies"
:
{
"accepts"
:
{
"version"
:
"1.3.7"
,
"resolved"
:
"https://registry.npmjs.org/accepts/-/accepts-1.3.7.tgz"
,
"integrity"
:
"sha512-Il80Qs2WjYlJIBNzNkK6KYqlVMTbZLXgHx2oT0pU/fjRHyEp+PEfEPY0R3WCwAGVOtauxh1hOxNgIf5bv7dQpA=="
,
"requires"
:
{
"mime-types"
:
"~2.1.24"
,
"negotiator"
:
"0.6.2"
}
},
"array-flatten"
:
{
"version"
:
"1.1.1"
,
"resolved"
:
"https://registry.npmjs.org/array-flatten/-/array-flatten-1.1.1.tgz"
,
"integrity"
:
"sha1-ml9pkFGx5wczKPKgCJaLZOopVdI="
},
"body-parser"
:
{
"version"
:
"1.19.0"
,
"resolved"
:
"https://registry.npmjs.org/body-parser/-/body-parser-1.19.0.tgz"
,
"integrity"
:
"sha512-dhEPs72UPbDnAQJ9ZKMNTP6ptJaionhP5cBb541nXPlW60Jepo9RV/a4fX4XWW9CuFNK22krhrj1+rgzifNCsw=="
,
"requires"
:
{
"bytes"
:
"3.1.0"
,
"content-type"
:
"~1.0.4"
,
"debug"
:
"2.6.9"
,
"depd"
:
"~1.1.2"
,
"http-errors"
:
"1.7.2"
,
"iconv-lite"
:
"0.4.24"
,
"on-finished"
:
"~2.3.0"
,
"qs"
:
"6.7.0"
,
"raw-body"
:
"2.4.0"
,
"type-is"
:
"~1.6.17"
}
},
"bytes"
:
{
"version"
:
"3.1.0"
,
"resolved"
:
"https://registry.npmjs.org/bytes/-/bytes-3.1.0.tgz"
,
"integrity"
:
"sha512-zauLjrfCG+xvoyaqLoV8bLVXXNGC4JqlxFCutSDWA6fJrTo2ZuvLYTqZ7aHBLZSMOopbzwv8f+wZcVzfVTI2Dg=="
},
"content-disposition"
:
{
"version"
:
"0.5.3"
,
"resolved"
:
"https://registry.npmjs.org/content-disposition/-/content-disposition-0.5.3.tgz"
,
"integrity"
:
"sha512-ExO0774ikEObIAEV9kDo50o+79VCUdEB6n6lzKgGwupcVeRlhrj3qGAfwq8G6uBJjkqLrhT0qEYFcWng8z1z0g=="
,
"requires"
:
{
"safe-buffer"
:
"5.1.2"
}
},
"content-type"
:
{
"version"
:
"1.0.4"
,
"resolved"
:
"https://registry.npmjs.org/content-type/-/content-type-1.0.4.tgz"
,
"integrity"
:
"sha512-hIP3EEPs8tB9AT1L+NUqtwOAps4mk2Zob89MWXMHjHWg9milF/j4osnnQLXBCBFBk/tvIG/tUc9mOUJiPBhPXA=="
},
"cookie"
:
{
"version"
:
"0.4.0"
,
"resolved"
:
"https://registry.npmjs.org/cookie/-/cookie-0.4.0.tgz"
,
"integrity"
:
"sha512-+Hp8fLp57wnUSt0tY0tHEXh4voZRDnoIrZPqlo3DPiI4y9lwg/jqx+1Om94/W6ZaPDOUbnjOt/99w66zk+l1Xg=="
},
"cookie-signature"
:
{
"version"
:
"1.0.6"
,
"resolved"
:
"https://registry.npmjs.org/cookie-signature/-/cookie-signature-1.0.6.tgz"
,
"integrity"
:
"sha1-4wOogrNCzD7oylE6eZmXNNqzriw="
},
"debug"
:
{
"version"
:
"2.6.9"
,
"resolved"
:
"https://registry.npmjs.org/debug/-/debug-2.6.9.tgz"
,
"integrity"
:
"sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA=="
,
"requires"
:
{
"ms"
:
"2.0.0"
}
},
"depd"
:
{
"version"
:
"1.1.2"
,
"resolved"
:
"https://registry.npmjs.org/depd/-/depd-1.1.2.tgz"
,
"integrity"
:
"sha1-m81S4UwJd2PnSbJ0xDRu0uVgtak="
},
"destroy"
:
{
"version"
:
"1.0.4"
,
"resolved"
:
"https://registry.npmjs.org/destroy/-/destroy-1.0.4.tgz"
,
"integrity"
:
"sha1-l4hXRCxEdJ5CBmE+N5RiBYJqvYA="
},
"ee-first"
:
{
"version"
:
"1.1.1"
,
"resolved"
:
"https://registry.npmjs.org/ee-first/-/ee-first-1.1.1.tgz"
,
"integrity"
:
"sha1-WQxhFWsK4vTwJVcyoViyZrxWsh0="
},
"encodeurl"
:
{
"version"
:
"1.0.2"
,
"resolved"
:
"https://registry.npmjs.org/encodeurl/-/encodeurl-1.0.2.tgz"
,
"integrity"
:
"sha1-rT/0yG7C0CkyL1oCw6mmBslbP1k="
},
"escape-html"
:
{
"version"
:
"1.0.3"
,
"resolved"
:
"https://registry.npmjs.org/escape-html/-/escape-html-1.0.3.tgz"
,
"integrity"
:
"sha1-Aljq5NPQwJdN4cFpGI7wBR0dGYg="
},
"etag"
:
{
"version"
:
"1.8.1"
,
"resolved"
:
"https://registry.npmjs.org/etag/-/etag-1.8.1.tgz"
,
"integrity"
:
"sha1-Qa4u62XvpiJorr/qg6x9eSmbCIc="
},
"express"
:
{
"version"
:
"4.17.1"
,
"resolved"
:
"https://registry.npmjs.org/express/-/express-4.17.1.tgz"
,
"integrity"
:
"sha512-mHJ9O79RqluphRrcw2X/GTh3k9tVv8YcoyY4Kkh4WDMUYKRZUq0h1o0w2rrrxBqM7VoeUVqgb27xlEMXTnYt4g=="
,
"requires"
:
{
"accepts"
:
"~1.3.7"
,
"array-flatten"
:
"1.1.1"
,
"body-parser"
:
"1.19.0"
,
"content-disposition"
:
"0.5.3"
,
"content-type"
:
"~1.0.4"
,
"cookie"
:
"0.4.0"
,
"cookie-signature"
:
"1.0.6"
,
"debug"
:
"2.6.9"
,
"depd"
:
"~1.1.2"
,
"encodeurl"
:
"~1.0.2"
,
"escape-html"
:
"~1.0.3"
,
"etag"
:
"~1.8.1"
,
"finalhandler"
:
"~1.1.2"
,
"fresh"
:
"0.5.2"
,
"merge-descriptors"
:
"1.0.1"
,
"methods"
:
"~1.1.2"
,
"on-finished"
:
"~2.3.0"
,
"parseurl"
:
"~1.3.3"
,
"path-to-regexp"
:
"0.1.7"
,
"proxy-addr"
:
"~2.0.5"
,
"qs"
:
"6.7.0"
,
"range-parser"
:
"~1.2.1"
,
"safe-buffer"
:
"5.1.2"
,
"send"
:
"0.17.1"
,
"serve-static"
:
"1.14.1"
,
"setprototypeof"
:
"1.1.1"
,
"statuses"
:
"~1.5.0"
,
"type-is"
:
"~1.6.18"
,
"utils-merge"
:
"1.0.1"
,
"vary"
:
"~1.1.2"
}
},
"finalhandler"
:
{
"version"
:
"1.1.2"
,
"resolved"
:
"https://registry.npmjs.org/finalhandler/-/finalhandler-1.1.2.tgz"
,
"integrity"
:
"sha512-aAWcW57uxVNrQZqFXjITpW3sIUQmHGG3qSb9mUah9MgMC4NeWhNOlNjXEYq3HjRAvL6arUviZGGJsBg6z0zsWA=="
,
"requires"
:
{
"debug"
:
"2.6.9"
,
"encodeurl"
:
"~1.0.2"
,
"escape-html"
:
"~1.0.3"
,
"on-finished"
:
"~2.3.0"
,
"parseurl"
:
"~1.3.3"
,
"statuses"
:
"~1.5.0"
,
"unpipe"
:
"~1.0.0"
}
},
"forwarded"
:
{
"version"
:
"0.1.2"
,
"resolved"
:
"https://registry.npmjs.org/forwarded/-/forwarded-0.1.2.tgz"
,
"integrity"
:
"sha1-mMI9qxF1ZXuMBXPozszZGw/xjIQ="
},
"fresh"
:
{
"version"
:
"0.5.2"
,
"resolved"
:
"https://registry.npmjs.org/fresh/-/fresh-0.5.2.tgz"
,
"integrity"
:
"sha1-PYyt2Q2XZWn6g1qx+OSyOhBWBac="
},
"http-errors"
:
{
"version"
:
"1.7.2"
,
"resolved"
:
"https://registry.npmjs.org/http-errors/-/http-errors-1.7.2.tgz"
,
"integrity"
:
"sha512-uUQBt3H/cSIVfch6i1EuPNy/YsRSOUBXTVfZ+yR7Zjez3qjBz6i9+i4zjNaoqcoFVI4lQJ5plg63TvGfRSDCRg=="
,
"requires"
:
{
"depd"
:
"~1.1.2"
,
"inherits"
:
"2.0.3"
,
"setprototypeof"
:
"1.1.1"
,
"statuses"
:
">= 1.5.0 < 2"
,
"toidentifier"
:
"1.0.0"
}
},
"iconv-lite"
:
{
"version"
:
"0.4.24"
,
"resolved"
:
"https://registry.npmjs.org/iconv-lite/-/iconv-lite-0.4.24.tgz"
,
"integrity"
:
"sha512-v3MXnZAcvnywkTUEZomIActle7RXXeedOR31wwl7VlyoXO4Qi9arvSenNQWne1TcRwhCL1HwLI21bEqdpj8/rA=="
,
"requires"
:
{
"safer-buffer"
:
">= 2.1.2 < 3"
}
},
"inherits"
:
{
"version"
:
"2.0.3"
,
"resolved"
:
"https://registry.npmjs.org/inherits/-/inherits-2.0.3.tgz"
,
"integrity"
:
"sha1-Yzwsg+PaQqUC9SRmAiSA9CCCYd4="
},
"ipaddr.js"
:
{
"version"
:
"1.9.1"
,
"resolved"
:
"https://registry.npmjs.org/ipaddr.js/-/ipaddr.js-1.9.1.tgz"
,
"integrity"
:
"sha512-0KI/607xoxSToH7GjN1FfSbLoU0+btTicjsQSWQlh/hZykN8KpmMf7uYwPW3R+akZ6R/w18ZlXSHBYXiYUPO3g=="
},
"media-typer"
:
{
"version"
:
"0.3.0"
,
"resolved"
:
"https://registry.npmjs.org/media-typer/-/media-typer-0.3.0.tgz"
,
"integrity"
:
"sha1-hxDXrwqmJvj/+hzgAWhUUmMlV0g="
},
"merge-descriptors"
:
{
"version"
:
"1.0.1"
,
"resolved"
:
"https://registry.npmjs.org/merge-descriptors/-/merge-descriptors-1.0.1.tgz"
,
"integrity"
:
"sha1-sAqqVW3YtEVoFQ7J0blT8/kMu2E="
},
"methods"
:
{
"version"
:
"1.1.2"
,
"resolved"
:
"https://registry.npmjs.org/methods/-/methods-1.1.2.tgz"
,
"integrity"
:
"sha1-VSmk1nZUE07cxSZmVoNbD4Ua/O4="
},
"mime"
:
{
"version"
:
"1.6.0"
,
"resolved"
:
"https://registry.npmjs.org/mime/-/mime-1.6.0.tgz"
,
"integrity"
:
"sha512-x0Vn8spI+wuJ1O6S7gnbaQg8Pxh4NNHb7KSINmEWKiPE4RKOplvijn+NkmYmmRgP68mc70j2EbeTFRsrswaQeg=="
},
"mime-db"
:
{
"version"
:
"1.44.0"
,
"resolved"
:
"https://registry.npmjs.org/mime-db/-/mime-db-1.44.0.tgz"
,
"integrity"
:
"sha512-/NOTfLrsPBVeH7YtFPgsVWveuL+4SjjYxaQ1xtM1KMFj7HdxlBlxeyNLzhyJVx7r4rZGJAZ/6lkKCitSc/Nmpg=="
},
"mime-types"
:
{
"version"
:
"2.1.27"
,
"resolved"
:
"https://registry.npmjs.org/mime-types/-/mime-types-2.1.27.tgz"
,
"integrity"
:
"sha512-JIhqnCasI9yD+SsmkquHBxTSEuZdQX5BuQnS2Vc7puQQQ+8yiP5AY5uWhpdv4YL4VM5c6iliiYWPgJ/nJQLp7w=="
,
"requires"
:
{
"mime-db"
:
"1.44.0"
}
},
"ms"
:
{
"version"
:
"2.0.0"
,
"resolved"
:
"https://registry.npmjs.org/ms/-/ms-2.0.0.tgz"
,
"integrity"
:
"sha1-VgiurfwAvmwpAd9fmGF4jeDVl8g="
},
"negotiator"
:
{
"version"
:
"0.6.2"
,
"resolved"
:
"https://registry.npmjs.org/negotiator/-/negotiator-0.6.2.tgz"
,
"integrity"
:
"sha512-hZXc7K2e+PgeI1eDBe/10Ard4ekbfrrqG8Ep+8Jmf4JID2bNg7NvCPOZN+kfF574pFQI7mum2AUqDidoKqcTOw=="
},
"on-finished"
:
{
"version"
:
"2.3.0"
,
"resolved"
:
"https://registry.npmjs.org/on-finished/-/on-finished-2.3.0.tgz"
,
"integrity"
:
"sha1-IPEzZIGwg811M3mSoWlxqi2QaUc="
,
"requires"
:
{
"ee-first"
:
"1.1.1"
}
},
"parseurl"
:
{
"version"
:
"1.3.3"
,
"resolved"
:
"https://registry.npmjs.org/parseurl/-/parseurl-1.3.3.tgz"
,
"integrity"
:
"sha512-CiyeOxFT/JZyN5m0z9PfXw4SCBJ6Sygz1Dpl0wqjlhDEGGBP1GnsUVEL0p63hoG1fcj3fHynXi9NYO4nWOL+qQ=="
},
"path-to-regexp"
:
{
"version"
:
"0.1.7"
,
"resolved"
:
"https://registry.npmjs.org/path-to-regexp/-/path-to-regexp-0.1.7.tgz"
,
"integrity"
:
"sha1-32BBeABfUi8V60SQ5yR6G/qmf4w="
},
"proxy-addr"
:
{
"version"
:
"2.0.6"
,
"resolved"
:
"https://registry.npmjs.org/proxy-addr/-/proxy-addr-2.0.6.tgz"
,
"integrity"
:
"sha512-dh/frvCBVmSsDYzw6n926jv974gddhkFPfiN8hPOi30Wax25QZyZEGveluCgliBnqmuM+UJmBErbAUFIoDbjOw=="
,
"requires"
:
{
"forwarded"
:
"~0.1.2"
,
"ipaddr.js"
:
"1.9.1"
}
},
"qs"
:
{
"version"
:
"6.7.0"
,
"resolved"
:
"https://registry.npmjs.org/qs/-/qs-6.7.0.tgz"
,
"integrity"
:
"sha512-VCdBRNFTX1fyE7Nb6FYoURo/SPe62QCaAyzJvUjwRaIsc+NePBEniHlvxFmmX56+HZphIGtV0XeCirBtpDrTyQ=="
},
"range-parser"
:
{
"version"
:
"1.2.1"
,
"resolved"
:
"https://registry.npmjs.org/range-parser/-/range-parser-1.2.1.tgz"
,
"integrity"
:
"sha512-Hrgsx+orqoygnmhFbKaHE6c296J+HTAQXoxEF6gNupROmmGJRoyzfG3ccAveqCBrwr/2yxQ5BVd/GTl5agOwSg=="
},
"raw-body"
:
{
"version"
:
"2.4.0"
,
"resolved"
:
"https://registry.npmjs.org/raw-body/-/raw-body-2.4.0.tgz"
,
"integrity"
:
"sha512-4Oz8DUIwdvoa5qMJelxipzi/iJIi40O5cGV1wNYp5hvZP8ZN0T+jiNkL0QepXs+EsQ9XJ8ipEDoiH70ySUJP3Q=="
,
"requires"
:
{
"bytes"
:
"3.1.0"
,
"http-errors"
:
"1.7.2"
,
"iconv-lite"
:
"0.4.24"
,
"unpipe"
:
"1.0.0"
}
},
"safe-buffer"
:
{
"version"
:
"5.1.2"
,
"resolved"
:
"https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.1.2.tgz"
,
"integrity"
:
"sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g=="
},
"safer-buffer"
:
{
"version"
:
"2.1.2"
,
"resolved"
:
"https://registry.npmjs.org/safer-buffer/-/safer-buffer-2.1.2.tgz"
,
"integrity"
:
"sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg=="
},
"send"
:
{
"version"
:
"0.17.1"
,
"resolved"
:
"https://registry.npmjs.org/send/-/send-0.17.1.tgz"
,
"integrity"
:
"sha512-BsVKsiGcQMFwT8UxypobUKyv7irCNRHk1T0G680vk88yf6LBByGcZJOTJCrTP2xVN6yI+XjPJcNuE3V4fT9sAg=="
,
"requires"
:
{
"debug"
:
"2.6.9"
,
"depd"
:
"~1.1.2"
,
"destroy"
:
"~1.0.4"
,
"encodeurl"
:
"~1.0.2"
,
"escape-html"
:
"~1.0.3"
,
"etag"
:
"~1.8.1"
,
"fresh"
:
"0.5.2"
,
"http-errors"
:
"~1.7.2"
,
"mime"
:
"1.6.0"
,
"ms"
:
"2.1.1"
,
"on-finished"
:
"~2.3.0"
,
"range-parser"
:
"~1.2.1"
,
"statuses"
:
"~1.5.0"
},
"dependencies"
:
{
"ms"
:
{
"version"
:
"2.1.1"
,
"resolved"
:
"https://registry.npmjs.org/ms/-/ms-2.1.1.tgz"
,
"integrity"
:
"sha512-tgp+dl5cGk28utYktBsrFqA7HKgrhgPsg6Z/EfhWI4gl1Hwq8B/GmY/0oXZ6nF8hDVesS/FpnYaD/kOWhYQvyg=="
}
}
},
"serve-static"
:
{
"version"
:
"1.14.1"
,
"resolved"
:
"https://registry.npmjs.org/serve-static/-/serve-static-1.14.1.tgz"
,
"integrity"
:
"sha512-JMrvUwE54emCYWlTI+hGrGv5I8dEwmco/00EvkzIIsR7MqrHonbD9pO2MOfFnpFntl7ecpZs+3mW+XbQZu9QCg=="
,
"requires"
:
{
"encodeurl"
:
"~1.0.2"
,
"escape-html"
:
"~1.0.3"
,
"parseurl"
:
"~1.3.3"
,
"send"
:
"0.17.1"
}
},
"setprototypeof"
:
{
"version"
:
"1.1.1"
,
"resolved"
:
"https://registry.npmjs.org/setprototypeof/-/setprototypeof-1.1.1.tgz"
,
"integrity"
:
"sha512-JvdAWfbXeIGaZ9cILp38HntZSFSo3mWg6xGcJJsd+d4aRMOqauag1C63dJfDw7OaMYwEbHMOxEZ1lqVRYP2OAw=="
},
"statuses"
:
{
"version"
:
"1.5.0"
,
"resolved"
:
"https://registry.npmjs.org/statuses/-/statuses-1.5.0.tgz"
,
"integrity"
:
"sha1-Fhx9rBd2Wf2YEfQ3cfqZOBR4Yow="
},
"toidentifier"
:
{
"version"
:
"1.0.0"
,
"resolved"
:
"https://registry.npmjs.org/toidentifier/-/toidentifier-1.0.0.tgz"
,
"integrity"
:
"sha512-yaOH/Pk/VEhBWWTlhI+qXxDFXlejDGcQipMlyxda9nthulaxLZUNcUqFxokp0vcYnvteJln5FNQDRrxj3YcbVw=="
},
"type-is"
:
{
"version"
:
"1.6.18"
,
"resolved"
:
"https://registry.npmjs.org/type-is/-/type-is-1.6.18.tgz"
,
"integrity"
:
"sha512-TkRKr9sUTxEH8MdfuCSP7VizJyzRNMjj2J2do2Jr3Kym598JVdEksuzPQCnlFPW4ky9Q+iA+ma9BGm06XQBy8g=="
,
"requires"
:
{
"media-typer"
:
"0.3.0"
,
"mime-types"
:
"~2.1.24"
}
},
"unpipe"
:
{
"version"
:
"1.0.0"
,
"resolved"
:
"https://registry.npmjs.org/unpipe/-/unpipe-1.0.0.tgz"
,
"integrity"
:
"sha1-sr9O6FFKrmFltIF4KdIbLvSZBOw="
},
"utils-merge"
:
{
"version"
:
"1.0.1"
,
"resolved"
:
"https://registry.npmjs.org/utils-merge/-/utils-merge-1.0.1.tgz"
,
"integrity"
:
"sha1-n5VxD1CiZ5R7LMwSR0HBAoQn5xM="
},
"vary"
:
{
"version"
:
"1.1.2"
,
"resolved"
:
"https://registry.npmjs.org/vary/-/vary-1.1.2.tgz"
,
"integrity"
:
"sha1-IpnwLG3tMNSllhsLn3RSShj2NPw="
}
}
}
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/messenger/webhook/package.json
0 → 100644
View file @
9fa45f8
{
"name"
:
"webhook"
,
"version"
:
"1.0.0"
,
"description"
:
""
,
"main"
:
"app.js"
,
"scripts"
:
{
"test"
:
"echo
\"
Error: no test specified
\"
&& exit 1"
},
"author"
:
""
,
"license"
:
"ISC"
,
"dependencies"
:
{
"body-parser"
:
"^1.19.0"
,
"express"
:
"^4.17.1"
}
}
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/nodejs/Assignments/01/app.js
0 → 100644
View file @
9fa45f8
// mymodule.js에 정의된 모듈로 불러서 사용하도록 처리
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/nodejs/Assignments/01/mymodule.js
0 → 100644
View file @
9fa45f8
// 아래 2개의 함수를 모듈로 정의하는 것이 필요함
function
add
(
a
,
b
)
{
return
a
+
b
;
}
function
sub
(
a
,
b
)
{
return
a
-
b
;
}
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/nodejs/Assignments/02/index.js
0 → 100644
View file @
9fa45f8
const
doSomethingAsync
=
()
=>
{
return
new
Promise
(
resolve
=>
{
setTimeout
(()
=>
resolve
(
'I did something'
),
3000
)
})
}
// doSomething 함수를 async await 형태로 변경하시오
const
doSomething
=
()
=>
{
doSomethingAsync
().
then
(
a
=>
console
.
log
(
a
))
}
console
.
log
(
'Before'
)
doSomething
()
console
.
log
(
'After'
)
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/nodejs/Tutorial/event01/app.js
0 → 100644
View file @
9fa45f8
var
events
=
require
(
'events'
);
var
eventEmitter
=
new
events
.
EventEmitter
();
var
connectHandler
=
function
connected
()
{
console
.
log
(
'connection successful.'
);
eventEmitter
.
emit
(
'data_received'
);
}
eventEmitter
.
on
(
'connection'
,
connectHandler
);
eventEmitter
.
on
(
'data_received'
,
function
(){
console
.
log
(
'data received successfully.'
);
});
eventEmitter
.
emit
(
'connection'
);
console
.
log
(
"Program Ended."
);
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/nodejs/Tutorial/event02/app.js
0 → 100644
View file @
9fa45f8
var
events
=
require
(
'events'
);
var
eventEmitter
=
new
events
.
EventEmitter
();
var
listner1
=
function
listner1
()
{
console
.
log
(
'listner1 executed.'
);
}
var
listner2
=
function
listner2
()
{
console
.
log
(
'listner2 executed.'
);
}
eventEmitter
.
addListener
(
'connection'
,
listner1
);
eventEmitter
.
on
(
'connection'
,
listner2
);
var
eventListeners
=
require
(
'events'
).
EventEmitter
.
listenerCount
(
eventEmitter
,
'connection'
);
console
.
log
(
eventListeners
+
" Listner(s) listening to connection event"
);
eventEmitter
.
emit
(
'connection'
);
eventEmitter
.
removeListener
(
'connection'
,
listner1
);
console
.
log
(
"Listner1 will not listen now."
);
eventEmitter
.
emit
(
'connection'
);
eventListeners
=
require
(
'events'
).
EventEmitter
.
listenerCount
(
eventEmitter
,
'connection'
);
console
.
log
(
eventListeners
+
" Listner(s) listening to connection event"
);
console
.
log
(
"Program Ended."
);
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/nodejs/Tutorial/mymodule/app.js
0 → 100644
View file @
9fa45f8
var
dt
=
require
(
'./mymodule'
);
console
.
log
(
dt
.
myDateTime
());
OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/OSS-master-4403739dc9ff27d1ddfa858dfba4a9c7397ad679/Experiments/nodejs/Tutorial/mymodule/mymodule.js
0 → 100644
View file @
9fa45f8
exports
.
myDateTime
=
function
()
{
return
Date
();
};
Please
register
or
login
to post a comment