{"id":45839,"date":"2022-11-20T17:09:56","date_gmt":"2022-11-10T11:45:23","guid":{"rendered":"https:\/\/www.silicloud.com\/zh\/blog\/45839-2\/"},"modified":"2024-04-29T01:38:48","modified_gmt":"2024-04-28T17:38:48","slug":"45839-2","status":"publish","type":"post","link":"https:\/\/www.silicloud.com\/zh\/blog\/45839-2\/","title":{"rendered":""},"content":{"rendered":"<h1>Jupyter notebook\u6700\u65b0\u7248\u306e\u30bb\u30ad\u30e5\u30ea\u30c6\u30a3<\/h1>\n<p>notebook\u30d1\u30c3\u30b1\u30fc\u30b8\u304c4.3\u306b\u306a\u3063\u3066\u304b\u3089\u3001\u30bb\u30ad\u30e5\u30ea\u30c6\u30a3\u304c\u5f37\u5316\u3055\u308c\u305f\u3088\u3046\u3067\u3059\u3002<br \/>\n\u53c2\u8003: Security in the Jupyter notebook server<\/p>\n<div><img decoding=\"async\" class=\"post-images\" title=\"\" src=\"https:\/\/cdn.silicloud.com\/blog-img\/blog\/img\/657d613237434c4406cfd0c5\/2-0.png\" alt=\"image\" \/><\/div>\n<p>\u4e0b\u8a18\u306e\u624b\u9806\u3067\u4f7f\u3048\u308b\u3088\u3046\u306b\u306a\u308a\u307e\u3059\u3002<\/p>\n<h2>(1) \u4e0b\u8a18\u306e\u3088\u3046\u306b\u8a2d\u5b9a\u30d5\u30a1\u30a4\u30eb\u3092\u4f5c\u6210\u3059\u308b\u3002<\/h2>\n<pre class=\"post-pre\"><code>jupyter notebook --generate-config\r\n<\/code><\/pre>\n<h2>(2) \u8a2d\u5b9a\u30d5\u30a1\u30a4\u30eb\u3092\u7de8\u96c6\u3059\u308b\u3002<\/h2>\n<p>\u7de8\u96c6\u65b9\u6cd5\u306f\u30012\u7a2e\u985e\u3042\u308a\u307e\u3059\u3002<\/p>\n<div>\n<div class=\"post-table\">\u65b9\u6cd5\u8a2d\u5b9a\u5185\u5bb9\u8aac\u660eAtoken\u3092\u8a2d\u5b9a\u5e73\u6587\u3067\u6587\u5b57\u3092\u6307\u5b9aBpassword\u3092\u8a2d\u5b9a\u6697\u53f7\u5316\u3057\u3066\u8a2d\u5b9a<\/div>\n<\/div>\n<h3>(2-A) token\u3092\u6307\u5b9a\u3059\u308b\u5834\u5408<\/h3>\n<p>\u4e0b\u8a18\u3092~\/.jupyter\/jupyter_notebook_config.py \u306b\u8ffd\u52a0\u3057\u3066\u304f\u3060\u3055\u3044\u3002(xxx\u306f\u9069\u5b9c\u5909\u3048\u3066\u304f\u3060\u3055\u3044)<\/p>\n<blockquote><p>c.NotebookApp.token = &#8216;xxx&#8217;<\/p><\/blockquote>\n<p>\u3053\u306e\u5834\u5408\u3001login\u753b\u9762\u306e\u30d1\u30b9\u30ef\u30fc\u30c9\u3068\u3057\u3066\u300cxxx\u300d\u3092\u5165\u529b\u3059\u308b\u304b\u3001\u30d6\u30e9\u30a6\u30b6\u306eURL\u3067\u4e0b\u8a18\u306e\u3088\u3046\u306b\u3059\u308b\u304b\u306e\u3069\u3061\u3089\u304b\u3067\u5229\u7528\u3067\u304d\u308b\u3088\u3046\u3067\u3059\u3002<\/p>\n<blockquote><p>http:\u30db\u30b9\u30c8\u306eURL:8888\/?token=xxx<\/p><\/blockquote>\n<h3>(2-B) password\u3092\u6307\u5b9a\u3059\u308b\u5834\u5408<\/h3>\n<p>\u307e\u305a\u3001python\u3067\u3001\u4e0b\u8a18\u3092\u5b9f\u884c\u3057\u3001\u30d1\u30b9\u30ef\u30fc\u30c9(\u4f8b\u3048\u3070 xxx)\u30922\u56de\u5165\u529b\u3057\u3001\u30cf\u30c3\u30b7\u30e5\u6587\u5b57\u3092\u53d6\u5f97\u3057\u3066\u304f\u3060\u3055\u3044\u3002<\/p>\n<pre class=\"post-pre\"><code>python -c 'from notebook.auth import passwd;print(passwd())'\r\n&gt;&gt;&gt;\r\nsha1:152704c5513c:0e0781437e7d013892eb7662f5ee5a67b235ec1a\r\n<\/code><\/pre>\n<p>~\/.jupyter\/jupyter_notebook_config.py \u306b\u4e0b\u8a18\u306e\u3088\u3046\u306b\u8ffd\u52a0\u3057\u3066\u304f\u3060\u3055\u3044\u3002<\/p>\n<blockquote><p>c.NotebookApp.password = &#8216;sha1:152704c5513c:0e0781437e7d013892eb7662f5ee5a67b235ec1a&#8217;<\/p><\/blockquote>\n<p>\u3053\u306e\u5834\u5408\u3001login\u753b\u9762\u3067\u6307\u5b9a\u3057\u305f\u30d1\u30b9\u30ef\u30fc\u30c9\u3067\u5165\u529b\u3067\u304d\u307e\u3059\u3002URL\u306e\u30aa\u30d7\u30b7\u30e7\u30f3\u306f\u4f7f\u3048\u306a\u3044\u3088\u3046\u3067\u3059\u3002<\/p>\n<h2>2022\/08\/02\u8ffd\u8a18<\/h2>\n<p>JupyterLab\u306e\u5834\u5408\u306e\u8aac\u660e\u30da\u30fc\u30b8\uff1ahttps:\/\/jupyter-server.readthedocs.io\/en\/latest\/operators\/public-server.html<\/p>\n<p>\u4ee5\u4e0a<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Jupyter notebook\u6700\u65b0\u7248\u306e\u30bb\u30ad\u30e5\u30ea\u30c6\u30a3 notebook\u30d1\u30c3\u30b1\u30fc\u30b8\u304c4.3\u306b\u306a\u3063\u3066\u304b\u3089\u3001\u30bb\u30ad\u30e5\u30ea [&hellip;]<\/p>\n","protected":false},"author":9,"featured_media":0,"comment_status":"closed","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[],"class_list":["post-45839","post","type-post","status-publish","format-standard","hentry","category-uncategorized"],"yoast_head":"<!-- This site is optimized with the Yoast SEO Premium plugin v21.5 (Yoast SEO v21.5) - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<title>- Blog - Silicon Cloud<\/title>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/www.silicloud.com\/zh\/blog\/45839-2\/\" \/>\n<meta property=\"og:locale\" content=\"zh_CN\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:description\" content=\"Jupyter notebook\u6700\u65b0\u7248\u306e\u30bb\u30ad\u30e5\u30ea\u30c6\u30a3 notebook\u30d1\u30c3\u30b1\u30fc\u30b8\u304c4.3\u306b\u306a\u3063\u3066\u304b\u3089\u3001\u30bb\u30ad\u30e5\u30ea [&hellip;]\" \/>\n<meta property=\"og:url\" content=\"https:\/\/www.silicloud.com\/zh\/blog\/45839-2\/\" \/>\n<meta property=\"og:site_name\" content=\"Blog - Silicon Cloud\" \/>\n<meta property=\"article:published_time\" content=\"2022-11-10T11:45:23+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2024-04-28T17:38:48+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/cdn.silicloud.com\/blog-img\/blog\/img\/657d613237434c4406cfd0c5\/2-0.png\" \/>\n<meta name=\"author\" content=\"\u6e05, \u626c\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"\u4f5c\u8005\" \/>\n\t<meta name=\"twitter:data1\" content=\"\u6e05, \u626c\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"WebPage\",\"@id\":\"https:\/\/www.silicloud.com\/zh\/blog\/45839-2\/\",\"url\":\"https:\/\/www.silicloud.com\/zh\/blog\/45839-2\/\",\"name\":\"- Blog - Silicon Cloud\",\"isPartOf\":{\"@id\":\"https:\/\/www.silicloud.com\/zh\/blog\/#website\"},\"datePublished\":\"2022-11-10T11:45:23+00:00\",\"dateModified\":\"2024-04-28T17:38:48+00:00\",\"author\":{\"@id\":\"https:\/\/www.silicloud.com\/zh\/blog\/#\/schema\/person\/cb5556d2501da73d864cac945e8d9461\"},\"inLanguage\":\"zh-Hans\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/www.silicloud.com\/zh\/blog\/45839-2\/\"]}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/www.silicloud.com\/zh\/blog\/#website\",\"url\":\"https:\/\/www.silicloud.com\/zh\/blog\/\",\"name\":\"Blog - Silicon Cloud\",\"description\":\"\",\"inLanguage\":\"zh-Hans\"},{\"@type\":\"Person\",\"@id\":\"https:\/\/www.silicloud.com\/zh\/blog\/#\/schema\/person\/cb5556d2501da73d864cac945e8d9461\",\"name\":\"\u6e05, \u626c\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"zh-Hans\",\"@id\":\"https:\/\/www.silicloud.com\/zh\/blog\/#\/schema\/person\/image\/\",\"url\":\"https:\/\/secure.gravatar.com\/avatar\/32a4239de8ff29adace466261d309424a1e5fe9f7e3036bf89fe03f2e3dbe717?s=96&d=mm&r=g\",\"contentUrl\":\"https:\/\/secure.gravatar.com\/avatar\/32a4239de8ff29adace466261d309424a1e5fe9f7e3036bf89fe03f2e3dbe717?s=96&d=mm&r=g\",\"caption\":\"\u6e05, \u626c\"},\"url\":\"https:\/\/www.silicloud.com\/zh\/blog\/author\/qingyang\/\"},{\"@type\":\"ImageObject\",\"inLanguage\":\"zh-Hans\",\"@id\":\"https:\/\/www.silicloud.com\/zh\/blog\/45839-2\/#local-main-organization-logo\",\"url\":\"\",\"contentUrl\":\"\",\"caption\":\"Blog - Silicon Cloud\"}]}<\/script>\n<!-- \/ Yoast SEO Premium plugin. -->","yoast_head_json":{"title":"- Blog - Silicon Cloud","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/www.silicloud.com\/zh\/blog\/45839-2\/","og_locale":"zh_CN","og_type":"article","og_description":"Jupyter notebook\u6700\u65b0\u7248\u306e\u30bb\u30ad\u30e5\u30ea\u30c6\u30a3 notebook\u30d1\u30c3\u30b1\u30fc\u30b8\u304c4.3\u306b\u306a\u3063\u3066\u304b\u3089\u3001\u30bb\u30ad\u30e5\u30ea [&hellip;]","og_url":"https:\/\/www.silicloud.com\/zh\/blog\/45839-2\/","og_site_name":"Blog - Silicon Cloud","article_published_time":"2022-11-10T11:45:23+00:00","article_modified_time":"2024-04-28T17:38:48+00:00","og_image":[{"url":"https:\/\/cdn.silicloud.com\/blog-img\/blog\/img\/657d613237434c4406cfd0c5\/2-0.png"}],"author":"\u6e05, \u626c","twitter_card":"summary_large_image","twitter_misc":{"\u4f5c\u8005":"\u6e05, \u626c"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"WebPage","@id":"https:\/\/www.silicloud.com\/zh\/blog\/45839-2\/","url":"https:\/\/www.silicloud.com\/zh\/blog\/45839-2\/","name":"- Blog - Silicon Cloud","isPartOf":{"@id":"https:\/\/www.silicloud.com\/zh\/blog\/#website"},"datePublished":"2022-11-10T11:45:23+00:00","dateModified":"2024-04-28T17:38:48+00:00","author":{"@id":"https:\/\/www.silicloud.com\/zh\/blog\/#\/schema\/person\/cb5556d2501da73d864cac945e8d9461"},"inLanguage":"zh-Hans","potentialAction":[{"@type":"ReadAction","target":["https:\/\/www.silicloud.com\/zh\/blog\/45839-2\/"]}]},{"@type":"WebSite","@id":"https:\/\/www.silicloud.com\/zh\/blog\/#website","url":"https:\/\/www.silicloud.com\/zh\/blog\/","name":"Blog - Silicon Cloud","description":"","inLanguage":"zh-Hans"},{"@type":"Person","@id":"https:\/\/www.silicloud.com\/zh\/blog\/#\/schema\/person\/cb5556d2501da73d864cac945e8d9461","name":"\u6e05, \u626c","image":{"@type":"ImageObject","inLanguage":"zh-Hans","@id":"https:\/\/www.silicloud.com\/zh\/blog\/#\/schema\/person\/image\/","url":"https:\/\/secure.gravatar.com\/avatar\/32a4239de8ff29adace466261d309424a1e5fe9f7e3036bf89fe03f2e3dbe717?s=96&d=mm&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/32a4239de8ff29adace466261d309424a1e5fe9f7e3036bf89fe03f2e3dbe717?s=96&d=mm&r=g","caption":"\u6e05, \u626c"},"url":"https:\/\/www.silicloud.com\/zh\/blog\/author\/qingyang\/"},{"@type":"ImageObject","inLanguage":"zh-Hans","@id":"https:\/\/www.silicloud.com\/zh\/blog\/45839-2\/#local-main-organization-logo","url":"","contentUrl":"","caption":"Blog - Silicon Cloud"}]}},"_links":{"self":[{"href":"https:\/\/www.silicloud.com\/zh\/blog\/wp-json\/wp\/v2\/posts\/45839","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.silicloud.com\/zh\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.silicloud.com\/zh\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.silicloud.com\/zh\/blog\/wp-json\/wp\/v2\/users\/9"}],"replies":[{"embeddable":true,"href":"https:\/\/www.silicloud.com\/zh\/blog\/wp-json\/wp\/v2\/comments?post=45839"}],"version-history":[{"count":2,"href":"https:\/\/www.silicloud.com\/zh\/blog\/wp-json\/wp\/v2\/posts\/45839\/revisions"}],"predecessor-version":[{"id":72261,"href":"https:\/\/www.silicloud.com\/zh\/blog\/wp-json\/wp\/v2\/posts\/45839\/revisions\/72261"}],"wp:attachment":[{"href":"https:\/\/www.silicloud.com\/zh\/blog\/wp-json\/wp\/v2\/media?parent=45839"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.silicloud.com\/zh\/blog\/wp-json\/wp\/v2\/categories?post=45839"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.silicloud.com\/zh\/blog\/wp-json\/wp\/v2\/tags?post=45839"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}