클라우드에서 보물 찾기 지도의 암호화 및 보관
모든 Wolfram 언어식은 암호화가 가능합니다.
Blowfish 방법을 사용한 비밀 암호에서 파생되어진 강력한 대칭 키를 생성합니다.
In[1]:=
![Click for copyable input](assets.ko/encrypt-and-store-a-treasure-map-on-the-cloud/In_32.png)
skeletonKey = GenerateSymmetricKey["Avast ye!", Method -> "Blowfish"]
Out[1]=
![](assets.ko/encrypt-and-store-a-treasure-map-on-the-cloud/O_27.png)
생성 된 키를 사용하여 보물의 소재를 암호화한 후, GeoMarker에 보관하고 GeoGraphics를 사용하여 시각화합니다.
전체 Wolfram 언어 입력 표시하기
Out[2]=
![](assets.ko/encrypt-and-store-a-treasure-map-on-the-cloud/O_28.png)
In[3]:=
![Click for copyable input](assets.ko/encrypt-and-store-a-treasure-map-on-the-cloud/In_34.png)
hiddenTreasure = Encrypt[skeletonKey, treasureMap]
Out[3]=
![](assets.ko/encrypt-and-store-a-treasure-map-on-the-cloud/O_29.png)
이제 로컬 키를 사용하여 데이터는 안전하게 암호화 되었습니다. 지도를 Wolfram Cloud에 업로드합니다.
In[4]:=
![Click for copyable input](assets.ko/encrypt-and-store-a-treasure-map-on-the-cloud/In_35.png)
stowed = CloudPut[hiddenTreasure]
추적되지 않도록 오리지널 지도와 키를 Clear를 사용하여 제거합니다.
In[5]:=
![Click for copyable input](assets.ko/encrypt-and-store-a-treasure-map-on-the-cloud/In_36.png)
Clear[hiddenTreasure]
In[6]:=
![Click for copyable input](assets.ko/encrypt-and-store-a-treasure-map-on-the-cloud/In_37.png)
Clear[skeletonKey]
이 키는 암호를 사용하여 만들어진 것이므로, 오리지널 입력을 사용한 새로운 키 생성이 가능합니다.
In[7]:=
![Click for copyable input](assets.ko/encrypt-and-store-a-treasure-map-on-the-cloud/In_38.png)
newKey = GenerateSymmetricKey["Avast ye!", Method -> "Blowfish"]
Out[7]=
![](assets.ko/encrypt-and-store-a-treasure-map-on-the-cloud/O_31.png)
이 새로운 키를 사용하여 클라우드에 배치 된 지도를 참조 할 수있습니다.
In[8]:=
![Click for copyable input](assets.ko/encrypt-and-store-a-treasure-map-on-the-cloud/In_39.png)
reclaimedMap = Decrypt[newKey, CloudGet[stowed]]
Out[8]=
![](assets.ko/encrypt-and-store-a-treasure-map-on-the-cloud/O_32.png)
보물의 소재를 추출합니다.
In[9]:=
![Click for copyable input](assets.ko/encrypt-and-store-a-treasure-map-on-the-cloud/In_40.png)
treasureLocation = reclaimedMap[[3, 2]]
Out[9]=
![](assets.ko/encrypt-and-store-a-treasure-map-on-the-cloud/O_33.png)
운전 경로를 묻습니다.
In[10]:=
![Click for copyable input](assets.ko/encrypt-and-store-a-treasure-map-on-the-cloud/In_41.png)
TravelDirections[{$GeoLocation, treasureLocation}]
![](assets.ko/index.ko/M_2.gif)
Out[10]=
![](assets.ko/encrypt-and-store-a-treasure-map-on-the-cloud/O_34.png)
GeoDistance를 사용하여 거리를 조사합니다.
In[11]:=
![Click for copyable input](assets.ko/encrypt-and-store-a-treasure-map-on-the-cloud/In_42.png)
GeoDistance[$GeoLocation, treasureLocation]
Out[11]=
![](assets.ko/encrypt-and-store-a-treasure-map-on-the-cloud/O_35.png)
이 거리를 바탕으로 보물에 가장 가까운 공항을 찾습니다.
In[12]:=
![Click for copyable input](assets.ko/encrypt-and-store-a-treasure-map-on-the-cloud/In_43.png)
airport = First[GeoNearest["Airport", treasureLocation]]
Out[12]=
![](assets.ko/encrypt-and-store-a-treasure-map-on-the-cloud/O_36.png)
그 공항에서 보물까지의 거리를 계산합니다.
In[13]:=
![Click for copyable input](assets.ko/encrypt-and-store-a-treasure-map-on-the-cloud/In_44.png)
GeoDistance[airport, treasureLocation]
Out[13]=
![](assets.ko/encrypt-and-store-a-treasure-map-on-the-cloud/O_37.png)