Giter Club home page Giter Club logo

amazeui's Introduction

en zh-cn

OpenNHP: Zero Trust Network-infrastructure Hiding Protocol

Build Status Version License

OpenNHP Logo

OpenNHP is an open-source implementation of the Network-infrastructure Hiding Protocol (NHP), a next-generation zero trust security protocol designed to secure network connections and hide infrastructure.


Table of Contents


Introduction

OpenNHP implements the Network-infrastructure Hiding Protocol (NHP), which operates at the session layer (layer 5) of the OSI model to enforce zero trust principles. NHP addresses key security challenges:

  • Mitigates vulnerability exploitation by enforcing "deny-all" rules by default
  • Prevents phishing attacks through encrypted DNS resolution
  • Protects against DDoS attacks by hiding infrastructure
  • Enables attack attribution through identity-based connections

NHP enhances security, reliability, and scalability compared to previous approaches like Single Packet Authorization (SPA).

🔐 OpenNHP is designed with security-first principles, implementing a true zero-trust architecture.


Key Features

  • Default-deny access control for all protected resources
  • Identity and device-based authentication before network access
  • Encrypted DNS resolution to prevent DNS hijacking
  • Distributed infrastructure to mitigate DDoS attacks
  • Scalable architecture with decoupled components
  • Integration with existing identity and access management systems
  • Support for various deployment models (client-to-gateway, client-to-server, etc)
  • Cryptographically secure using modern algorithms (ECC, Noise Protocol, IBC)
Click to expand feature details
  • Default-deny access control: All resources are hidden by default, only becoming accessible after authentication and authorization.
  • Identity and device-based authentication: Ensures that only known users on approved devices can gain access.
  • Encrypted DNS resolution: Prevents DNS hijacking and associated phishing attacks.
  • DDoS mitigation: Distributed infrastructure design helps protect against Distributed Denial of Service attacks.
  • Scalable architecture: Decoupled components allow for flexible deployment and scaling.
  • IAM integration: Works with your existing Identity and Access Management systems.
  • Flexible deployment: Supports various models including client-to-gateway, client-to-server, and more.
  • Strong cryptography: Utilizes modern algorithms like ECC, Noise Protocol, and IBC for robust security.

Quick Start

Get OpenNHP up and running in minutes:

git clone https://github.com/opennhp/nhp.git
cd nhp
make
./nhp-server run

Installation

Detailed installation instructions:

  1. Clone the repository:
    git clone https://github.com/opennhp/nhp.git
  2. Navigate to the project directory:
    cd nhp
  3. Build the project:
    make
  4. Install (optional):
    sudo make install

⚠️ Note: Running sudo make install requires root privileges. Make sure you trust the source before running this command.


Usage Example

Here's a simple example of using OpenNHP to secure a connection:

from opennhp import NHPClient

client = NHPClient("config.yaml")
connection = client.connect("protected-resource-id")
response = connection.send("Hello, secure world!")
print(response)

Dependencies

OpenNHP requires the following major dependencies:

Dependency Minimum Version
OpenSSL 1.1.1
Boost 1.66
Protocol Buffers 3.0

Architecture

OpenNHP follows a modular architecture with the following core components:

  • NHP-Agent: Client-side component that initiates requests
  • NHP-Server: Processes requests and manages authentication
  • NHP-AC: Enforces access policies on protected resources

These interact with:

  • Protected Resources: Applications, servers, network devices to be secured
  • Authorization Service Provider: Validates access policies

Components

NHP-Agent

The NHP-Agent is a client-side component that initiates communication and requests access to protected resources. It can be implemented as:

  • A standalone client application
  • An SDK integrated into existing applications
  • A browser plugin
  • A mobile app

The agent is responsible for:

  • Generating and sending knock requests to the NHP-Server
  • Maintaining secure communication channels
  • Handling authentication flows

NHP-Server

The NHP-Server is the central controller that:

  • Processes and validates knock requests from agents
  • Interacts with the Authorization Service Provider for policy decisions
  • Manages NHP-AC components to allow/deny access
  • Handles key management and cryptographic operations

It can be deployed in a distributed or clustered configuration for high availability and scalability.

NHP-AC

NHP-AC (Access Control) components enforce access policies on protected resources. Key functions:

  • Implement default deny-all rules
  • Open/close access based on NHP-Server instructions
  • Ensure network invisibility of protected resources
  • Log access attempts

Workflow

  1. NHP-Agent sends knock request to NHP-Server
  2. NHP-Server validates request and retrieves agent info
  3. NHP-Server queries Authorization Service Provider
  4. If authorized, NHP-Server instructs NHP-AC to allow access
  5. NHP-AC opens connection and notifies NHP-Server
  6. NHP-Server provides resource access details to NHP-Agent
  7. NHP-Agent can now access the protected resource
  8. Access is logged for auditing purposes

Deployment Models

OpenNHP supports multiple deployment models to suit different use cases:

  • Client-to-Gateway: Secures access to multiple servers behind a gateway
  • Client-to-Server: Directly secures individual servers/applications
  • Server-to-Server: Secures communication between backend services
  • Gateway-to-Gateway: Secures site-to-site connections

Security Benefits

  • Reduces attack surface by hiding infrastructure
  • Prevents unauthorized network reconnaissance
  • Mitigates vulnerability exploitation
  • Stops phishing via encrypted DNS
  • Protects against DDoS attacks
  • Enables fine-grained access control
  • Provides identity-based connection tracking

Cryptographic Foundations

OpenNHP leverages state-of-the-art cryptographic algorithms:

  • Elliptic Curve Cryptography (ECC): For efficient public key operations
  • Noise Protocol Framework: For secure key exchange and identity verification
  • Identity-Based Cryptography (IBC): For simplified key management at scale

Comparison to SPA

NHP offers several advantages over Single Packet Authorization (SPA):

  • Decoupled architecture improves scalability
  • Bidirectional communication increases reliability
  • Modern cryptographic primitives enhance security
  • More comprehensive infrastructure hiding capabilities
  • Extensible design supports various use cases
  • Interoperable with existing protocols and systems

Compatibility

OpenNHP is designed for broad compatibility:

Cryptographic Algorithms

  • International algorithms: Curve25519, AES, SHA256

Operating Systems

  • Windows
  • macOS
  • Linux (various distributions)
  • iOS
  • Android

CPU Architectures

  • x86
  • ARM
  • RISC-V
  • MIPS

Roadmap

Our plans for the near future include:


Contributing

We welcome contributions to OpenNHP! Please see our Contributing Guidelines for more information on how to get involved.


Acknowledgments

We'd like to thank the Cloud Security Alliance for their work on the SDP specification, which inspired many aspects of NHP.


License

OpenNHP is released under the Apache 2.0 License.


Contact

For more detailed documentation, please visit our Official Documentation.


🌟 Thank you for your interest in OpenNHP! We look forward to your contributions and feedback.

amazeui's People

Contributors

agileago avatar aidistan avatar billtec avatar evi1m0 avatar fay-jai avatar geminiwen avatar hongdp avatar huangshaoyan avatar huangzhipeng avatar jin0121 avatar justin-layerv avatar karlew avatar kkirsche avatar legend0858 avatar minwe avatar msdlisper avatar peterdavehello avatar poppinlp avatar prayagverma avatar rural21st avatar tombyrer avatar wilesun avatar windcbf avatar yinheli avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

amazeui's Issues

amazeui-master中demo的路由是怎么弄的?

router.get('/:component', function(req, res) {
var component = req.params.component;
res.redirect('/#' + component);
});
geg时怎么引入component变量的?不是express的router.get("index",function(req,res))吗!怎么可以换成变量
还有就是res.redirect重定向的地址怎么是#xxxx,其他js中也没看到对相应请求的get啊

关于gulp的一点问题

确认一下,我执行gulp后的结果一直停在下面,是就这样吗?

[11:22:33] Finished 'widgetsFile' after 24 ms
[11:22:33] Starting 'copyWidgetJs'...
[11:22:33] Start copy UI js files to build dir....
[11:22:33] Starting 'buildLess'...
[11:22:33] Finished 'buildLess' after 5.87 ms
[11:22:33] Starting 'hbsHelper'...
[11:22:33] Finished 'hbsHelper' after 4.91 ms
[11:22:33] Starting 'watch'...


[11:22:33] Finished 'watch' after 192 ms
[11:22:34] Finished 'copyWidgetJs' after 1.08 s
[11:22:34] Starting 'copyUIJs'...
[11:22:34] Finished 'copyUIJs' after 26 ms
[11:22:34] Starting 'transport'...
[11:22:34] Finished 'transport' after 777 ms
[11:22:34] Starting 'concat'...
[11:22:36] Finished 'concat' after 1.66 s


[11:22:36] Starting 'clean'...
[11:22:36] Finished build js, cleaning...
[11:22:36] Finished 'clean' after 2.71 ms
[11:22:36] Starting 'buildJs'...
[11:22:36] Finished 'buildJs' after 8.56 μs
[11:22:36] Starting 'default'...
[11:22:36] Finished 'default' after 9.19 μs

另外,gulp中主要做的是为了生成dist目录里的东西吧,有几个编译后会变的文件是该放入.gitignore吗

    modified:   dist/assets/js/amui.js
    modified:   dist/assets/js/amui.min.js
    modified:   less/amui.all.less

框架文件还是太大

压缩后css+js一起,也要有400kb以上,太大了,是bootstrap的2倍多。

希望能够想办法尽量瘦身,个人感觉在300kb左右,可以接受。

还要说下,这个框架真得不错!呵呵

JS选项卡组件致命问题,官方速查!

错误DEMO: 【复制下面的段落并且chrome切换到移动设备模拟,滑动主体试试】
★ 请打开下面网址复制和查看源码
http://jsfiddle.net/xpbox8oo/

当你给 am-tab-panel容器内加入任何标签之后, 选项卡切换就出现故障,【注意,我给切换卡主体全的文本全部包了个h1,你也可以多放点其他标签进来】

但如果你直接给 am-tab-panel容器内加入文本节点,那么移动端可以通过 文本节点的触控范围来切换选项卡

BUG:
1.只能在am-tab-panel里面插入文本节点,不能插入任何标签,,否则选项卡故障!

留言:
这么致命的问题请开发人员速速排查解决! 拖了我的进度啦TAT..不过很感谢你们的贡献!让我们能够使用到这么好的产品

AMUI 1.0 Beta2

CSS

  • 基本样式
  • 样式统一Normalize
  • 基础设置Base
  • 文字排版Typography
  • 打印样式Print
  • 网格Grid
  • 等分区块Block Grid
  • 辅助类Utility
  • 按钮Button
  • 代码Code
  • 表单Form
  • 图片Image
  • 表格Table
  • 小徽章Badge
  • 面包屑导航Breadcrumb
  • 按钮组Button-group
  • 关闭按钮Close
  • 评论列表Comment
  • 图标Icon
  • 输入框组Input-group
  • 列表List
  • 导航Nav
  • 导航条Topbar
  • 分页Pagination
  • 面板Panel
  • 进度条Progress
  • 缩略图Thumbnail
  • CSS 动画Animation
  • 文章页Article

JS 插件

  • Alert
  • Button
  • Collapse
  • Dropdown #77 #78
  • Modal
  • Popover
  • Progress
  • Slider
  • OffCanvas
  • ScrollSpy
  • ScrollSpyNav
  • Smooth Scroll #35
  • Sticky #55
  • Tabs
  • Cookie
  • FastClick
  • FullScreen

Web 组件

官方组件

  • 折叠面板Accordion
  • 分割线Divider
  • 单张图片Figure
  • 页脚Footer
  • 图片画廊Gallery
  • 回顶部Gotop #6
  • 页头Header
  • 简介Intro
  • 内容列表List
  • 菜单Menu
  • 工具栏Navbar
  • 分页Pagination
  • 段落Paragraph
  • 图片轮播Slider
  • 选项卡Tabs
  • 标题栏Titlebar

第三方组件

  • 多说Duoshuo
  • 百度地图Map
  • 美洽客服Mechat
  • 搜狐畅言Changyan

am-margin-top-lg am-padding-top-lg 错误

.am-margin-top-lg 这个样式应该只有margin-top才对,Firebug查看实际却是同时有margin-top:2.4rem和padding-top:2.4rem;

  1. .am-padding-top-lg 这个样式不存在;
  2. 请检查.am-margin和.am-padding是否与文档里说明的一致!

z-index 统计

减少 z-index 乱入,所有组件中 z-index 统计目录:

能否增加本地存储相关的信息

最近看了禅道的前端框架 zui发现其中有一个很好的特性希望能够被支持
http://zui.sexy/docs/javascript.html#store

本地存储的支持, 之所以这样说是因为我的项目中有一些影音文件和js文件比较大,客户每次访问都需要下载,不知道能不能够实现这个存储东西来指定存数对象 第二次之后的访问可以直接调取存数的对象

sticky组件有bug

this.original = {
      offsetTop: this.$element.offset().top,
      width: this.$element.width()
 };

这样初始化就计算了offsetTop,后面动态给固定元素前的内容添加内容,会导致滚动固定不准确。

手机上的.am-icon-bars样式的三横和.am-icon-caret-down样式的下三角图标不见了

我发现了个问题,在手机上类似
.am-icon-caret-down:before {
content: "\f0d7";
}
的CSS不起作用,导致了am-icon-bars的三横, .am-icon-caret-down的下三角图标不显示(不晓得是不是这个原因哈)
我是直接用在http://amazeui.org/getting-started 下载的妹子UI里的示例, 用coolpad8702 4G android4.3 欧鹏/自带的浏览器实验的
后来我用其它手机测试,居然没问题,这是手机的兼容性问题

重新规划 CSS 单位的使用

除了考虑可访性问题,还应该考虑:

  • IE8 支持;
  • 需要精确到像素级别的场景:比如左右两个元素垂直对齐,使用 em/rem 有的浏览器计算出来会有细微的差异

Figure 组件图片弹出后触发关闭操作改进

目前点击非图片区域时才可以关闭图片,在图片比例和视口比例对应时没有空白区域可点击,两个思路:

  • 增加额外的关闭按钮
  • 直接点击图片也能关闭(需要判断用户是进行 Pinch 操作还是 Tap 操作)

主机商说占用资源过多

在wordpress我将一个分类取出来,单独用amazeui来写了一个页面来显示,然后放主机上。
早上被告之站点占用资源过多关闭了,然后我将amazeui这个文件夹删了之后,网站才可以,不知是什么原因?

我是直接用demo里面的页面来的,会不会是因为里面的一些链接的问题?比如js,css文件。。。

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.